@conloca/mdx 0.1.16 → 0.2.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.
Files changed (86) hide show
  1. package/README.md +50 -16
  2. package/dist/code-block-frame.js +1 -0
  3. package/dist/code-block-frame.js.map +1 -0
  4. package/dist/editor-core.d.ts +0 -2
  5. package/dist/editor-core.d.ts.map +1 -1
  6. package/dist/editor-core.js +50 -6
  7. package/dist/editor-core.js.map +1 -0
  8. package/dist/esm-passthrough.d.ts +36 -0
  9. package/dist/esm-passthrough.d.ts.map +1 -0
  10. package/dist/esm-passthrough.js +237 -0
  11. package/dist/esm-passthrough.js.map +1 -0
  12. package/dist/fragments.d.ts +37 -0
  13. package/dist/fragments.d.ts.map +1 -0
  14. package/dist/fragments.js +53 -0
  15. package/dist/fragments.js.map +1 -0
  16. package/dist/index.d.ts +0 -2
  17. package/dist/index.d.ts.map +1 -1
  18. package/dist/index.js +1 -1
  19. package/dist/index.js.map +1 -0
  20. package/dist/markdown-options.js +1 -0
  21. package/dist/markdown-options.js.map +1 -0
  22. package/dist/mdx/compile-request.d.ts +5 -0
  23. package/dist/mdx/compile-request.d.ts.map +1 -0
  24. package/dist/mdx/compile-request.js +40 -0
  25. package/dist/mdx/compile-request.js.map +1 -0
  26. package/dist/mdx/compile.d.ts.map +1 -1
  27. package/dist/mdx/compile.js +21 -1
  28. package/dist/mdx/compile.js.map +1 -0
  29. package/dist/mdx/evaluate.d.ts +18 -23
  30. package/dist/mdx/evaluate.d.ts.map +1 -1
  31. package/dist/mdx/evaluate.js +103 -29
  32. package/dist/mdx/evaluate.js.map +1 -0
  33. package/dist/mdx/heading-outline.d.ts +46 -0
  34. package/dist/mdx/heading-outline.d.ts.map +1 -0
  35. package/dist/mdx/heading-outline.js +114 -0
  36. package/dist/mdx/heading-outline.js.map +1 -0
  37. package/dist/mdx/restrict-expressions.d.ts +43 -0
  38. package/dist/mdx/restrict-expressions.d.ts.map +1 -0
  39. package/dist/mdx/restrict-expressions.js +160 -0
  40. package/dist/mdx/restrict-expressions.js.map +1 -0
  41. package/dist/mdx-editor.js +1 -0
  42. package/dist/mdx-editor.js.map +1 -0
  43. package/dist/node.d.ts +3 -2
  44. package/dist/node.d.ts.map +1 -1
  45. package/dist/node.js +3 -1
  46. package/dist/node.js.map +1 -0
  47. package/dist/sandbox-frame.d.ts +114 -0
  48. package/dist/sandbox-frame.d.ts.map +1 -0
  49. package/dist/sandbox-frame.js +234 -0
  50. package/dist/sandbox-frame.js.map +1 -0
  51. package/dist/types.d.ts +7 -4
  52. package/dist/types.d.ts.map +1 -1
  53. package/dist/types.js +1 -0
  54. package/dist/types.js.map +1 -0
  55. package/package.json +58 -41
  56. package/src/code-block-frame.tsx +262 -0
  57. package/src/editor-core.tsx +403 -0
  58. package/src/editor-styles.css +282 -0
  59. package/src/esm-passthrough.ts +269 -0
  60. package/src/fragments.ts +91 -0
  61. package/src/index.ts +5 -0
  62. package/src/markdown-options.ts +21 -0
  63. package/src/mdx/compile-request.ts +53 -0
  64. package/src/mdx/compile.ts +51 -0
  65. package/src/mdx/evaluate.ts +144 -0
  66. package/src/mdx/heading-outline.ts +153 -0
  67. package/src/mdx/restrict-expressions.ts +173 -0
  68. package/src/mdx-editor.tsx +15 -0
  69. package/src/node.ts +25 -0
  70. package/src/sandbox-frame.ts +277 -0
  71. package/src/types.ts +23 -0
  72. package/dist/blocks.d.ts +0 -37
  73. package/dist/blocks.d.ts.map +0 -1
  74. package/dist/blocks.js +0 -51
  75. package/dist/hooks/useMDXEvaluation.d.ts +0 -28
  76. package/dist/hooks/useMDXEvaluation.d.ts.map +0 -1
  77. package/dist/hooks/useMDXEvaluation.js +0 -117
  78. package/dist/index.d.mts +0 -127
  79. package/dist/index.d.mts.map +0 -1
  80. package/dist/index.mjs +0 -516
  81. package/dist/index.mjs.map +0 -1
  82. package/dist/node.d.mts +0 -102
  83. package/dist/node.d.mts.map +0 -1
  84. package/dist/node.mjs +0 -140
  85. package/dist/node.mjs.map +0 -1
  86. package/dist/style.css +0 -88
package/dist/node.d.mts DELETED
@@ -1,102 +0,0 @@
1
- import { ComponentType } from "react";
2
- import { MDXCompileResponse as MDXCompileResult } from "@conloca/content-api";
3
- //#region src/types.d.ts
4
- interface EvaluatedMDXBlock {
5
- ok: true;
6
- id: string;
7
- title: string;
8
- Component: ComponentType;
9
- }
10
- interface FailedMDXBlockEvaluation {
11
- ok: false;
12
- id: string;
13
- title: string;
14
- error: Error;
15
- }
16
- type MDXBlockEvaluationResult = EvaluatedMDXBlock | FailedMDXBlockEvaluation;
17
- //#endregion
18
- //#region src/blocks.d.ts
19
- interface BlockLocaleSummary {
20
- meta?: {
21
- title?: string;
22
- };
23
- name?: string;
24
- }
25
- interface BlockManifest {
26
- id: string;
27
- locales: Record<string, BlockLocaleSummary | undefined>;
28
- }
29
- interface BlockLocalizedEntry {
30
- localized?: {
31
- meta?: {
32
- title?: string;
33
- };
34
- name?: string;
35
- content?: {
36
- mdx?: string;
37
- };
38
- };
39
- }
40
- interface BlockAPI {
41
- listAllContent(filters: {
42
- kind: 'block';
43
- }): Iterable<BlockManifest>;
44
- getLocalized(id: string, locale: string): Promise<BlockLocalizedEntry | null>;
45
- }
46
- /**
47
- * Evaluate all MDX blocks from a compatible content API.
48
- *
49
- * Returns structured success/error results so callers can decide how to
50
- * surface broken blocks instead of hardcoding fallback UI in this package.
51
- */
52
- declare function evaluateMDXBlocks(api: BlockAPI, locale: string): Promise<MDXBlockEvaluationResult[]>;
53
- //#endregion
54
- //#region src/mdx/compile.d.ts
55
- declare function compileMDX(content: string): Promise<MDXCompileResult>;
56
- //#endregion
57
- //#region src/mdx/evaluate.d.ts
58
- /**
59
- * Evaluate MDX content string to a React component.
60
- *
61
- * This is a framework-agnostic utility for converting MDX strings into
62
- * executable React components. Works in any Node.js environment (Astro,
63
- * Next.js, Remix, etc.) at build time or server-side.
64
- *
65
- * **When to use:**
66
- * - Building static sites with MDX content
67
- * - Server-side rendering MDX as React components
68
- * - Need React components (not HTML strings)
69
- *
70
- * @param mdxContent - The MDX string to evaluate
71
- * @param options - Optional configuration
72
- * @param options.development - Whether to use development mode (default: false)
73
- * @returns Object containing Component (or null) and optional error
74
- *
75
- * @example
76
- * ```typescript
77
- * import { evaluateMDXToComponent } from '@conloca/mdx/node';
78
- *
79
- * const { Component, error } = await evaluateMDXToComponent('# Hello\n\nThis is **MDX**');
80
- * if (error) {
81
- * console.error('Failed to evaluate:', error);
82
- * } else if (Component) {
83
- * // Render <Component /> in your React app
84
- * }
85
- * ```
86
- *
87
- * @example
88
- * ```typescript
89
- * // In Astro pages
90
- * const { Component } = await evaluateMDXToComponent(mdxContent);
91
- * // Then render in JSX: <Component />
92
- * ```
93
- */
94
- declare function evaluateMDXToComponent(mdxContent: string, options?: {
95
- development?: boolean;
96
- }): Promise<{
97
- Component: ComponentType | null;
98
- error?: Error;
99
- }>;
100
- //#endregion
101
- export { type EvaluatedMDXBlock, type FailedMDXBlockEvaluation, type MDXBlockEvaluationResult, type MDXCompileResult, compileMDX, evaluateMDXBlocks, evaluateMDXToComponent };
102
- //# sourceMappingURL=node.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"node.d.mts","names":[],"sources":["../src/types.ts","../src/blocks.ts","../src/mdx/compile.ts","../src/mdx/evaluate.ts"],"mappings":";;;UAIiB;EACf;EACA;EACA;EACA,WAAW;;UAGI;EACf;EACA;EACA;EACA,OAAO;;KAGG,2BAA2B,oBAAoB;;;UCfjD;EACR;IACE;;EAEF;;UAGQ;EACR;EACA,SAAS,eAAe;;UAGhB;EACR;IACE;MACE;;IAEF;IACA;MACE;;;;UAKI;EACR,eAAe;IAAW;MAAkB,SAAS;EACrD,aAAa,YAAY,iBAAiB,QAAQ;;;;;;;;iBAS9B,kBAAkB,KAAK,UAAU,iBAAiB,QAAQ;;;iBC/B1D,WAAW,kBAAkB,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBCoCrC,uBACpB,oBACA;EAAY;IACX;EAAU,WAAW;EAAsB,QAAQ"}
package/dist/node.mjs DELETED
@@ -1,140 +0,0 @@
1
- import * as runtime from "react/jsx-runtime";
2
- import { compile, evaluate } from "@mdx-js/mdx";
3
- import remarkFrontmatter from "remark-frontmatter";
4
- import remarkGfm from "remark-gfm";
5
- import remarkMdxFrontmatter from "remark-mdx-frontmatter";
6
- import matter from "gray-matter";
7
- //#region src/mdx/evaluate.ts
8
- /**
9
- * Evaluate MDX content string to a React component.
10
- *
11
- * This is a framework-agnostic utility for converting MDX strings into
12
- * executable React components. Works in any Node.js environment (Astro,
13
- * Next.js, Remix, etc.) at build time or server-side.
14
- *
15
- * **When to use:**
16
- * - Building static sites with MDX content
17
- * - Server-side rendering MDX as React components
18
- * - Need React components (not HTML strings)
19
- *
20
- * @param mdxContent - The MDX string to evaluate
21
- * @param options - Optional configuration
22
- * @param options.development - Whether to use development mode (default: false)
23
- * @returns Object containing Component (or null) and optional error
24
- *
25
- * @example
26
- * ```typescript
27
- * import { evaluateMDXToComponent } from '@conloca/mdx/node';
28
- *
29
- * const { Component, error } = await evaluateMDXToComponent('# Hello\n\nThis is **MDX**');
30
- * if (error) {
31
- * console.error('Failed to evaluate:', error);
32
- * } else if (Component) {
33
- * // Render <Component /> in your React app
34
- * }
35
- * ```
36
- *
37
- * @example
38
- * ```typescript
39
- * // In Astro pages
40
- * const { Component } = await evaluateMDXToComponent(mdxContent);
41
- * // Then render in JSX: <Component />
42
- * ```
43
- */
44
- async function evaluateMDXToComponent(mdxContent, options) {
45
- try {
46
- const { default: MDXComponent } = await evaluate(mdxContent, {
47
- ...runtime,
48
- remarkPlugins: [
49
- remarkFrontmatter,
50
- remarkMdxFrontmatter,
51
- remarkGfm
52
- ],
53
- development: options?.development ?? false
54
- });
55
- return { Component: MDXComponent };
56
- } catch (error) {
57
- return {
58
- Component: null,
59
- error: error instanceof Error ? error : /* @__PURE__ */ new Error("MDX evaluation failed")
60
- };
61
- }
62
- }
63
- //#endregion
64
- //#region src/blocks.ts
65
- /**
66
- * Evaluate all MDX blocks from a compatible content API.
67
- *
68
- * Returns structured success/error results so callers can decide how to
69
- * surface broken blocks instead of hardcoding fallback UI in this package.
70
- */
71
- async function evaluateMDXBlocks(api, locale) {
72
- const blocks = Array.from(api.listAllContent({ kind: "block" }));
73
- return Promise.all(blocks.map(async (block) => {
74
- const locales = Object.keys(block.locales);
75
- const firstLocale = locales.length > 0 ? block.locales[locales[0]] : null;
76
- const manifestTitle = firstLocale?.meta?.title || firstLocale?.name || block.id;
77
- try {
78
- const blockLocalized = await api.getLocalized(block.id, locale);
79
- const blockTitle = blockLocalized?.localized?.meta?.title || blockLocalized?.localized?.name || manifestTitle;
80
- const mdxContent = blockLocalized?.localized?.content?.mdx;
81
- if (!mdxContent) return {
82
- ok: false,
83
- id: block.id,
84
- title: blockTitle,
85
- error: /* @__PURE__ */ new Error(`No MDX content found for block: ${block.id}`)
86
- };
87
- const { Component: EvaluatedComponent, error } = await evaluateMDXToComponent(mdxContent);
88
- if (error || !EvaluatedComponent) return {
89
- ok: false,
90
- id: block.id,
91
- title: blockTitle,
92
- error: error || /* @__PURE__ */ new Error(`MDX evaluation failed for block: ${block.id}`)
93
- };
94
- return {
95
- ok: true,
96
- id: block.id,
97
- title: blockTitle,
98
- Component: EvaluatedComponent
99
- };
100
- } catch (error) {
101
- return {
102
- ok: false,
103
- id: block.id,
104
- title: manifestTitle,
105
- error: error instanceof Error ? error : /* @__PURE__ */ new Error(`Failed to evaluate block: ${block.id}`)
106
- };
107
- }
108
- }));
109
- }
110
- //#endregion
111
- //#region src/mdx/compile.ts
112
- async function compileMDX(content) {
113
- try {
114
- const { data: metadata } = matter(content, {});
115
- const compiled = await compile(content, {
116
- outputFormat: "function-body",
117
- development: process.env.NODE_ENV === "development",
118
- remarkPlugins: [
119
- remarkFrontmatter,
120
- remarkMdxFrontmatter,
121
- remarkGfm
122
- ]
123
- });
124
- return {
125
- code: String(compiled.value),
126
- metadata
127
- };
128
- } catch (error) {
129
- if (error instanceof Error) {
130
- const enhancedError = /* @__PURE__ */ new Error(`MDX compilation failed: ${error.message}`);
131
- enhancedError.stack = error.stack;
132
- throw enhancedError;
133
- }
134
- throw error;
135
- }
136
- }
137
- //#endregion
138
- export { compileMDX, evaluateMDXBlocks, evaluateMDXToComponent };
139
-
140
- //# sourceMappingURL=node.mjs.map
package/dist/node.mjs.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"node.mjs","names":["mdxCompile"],"sources":["../src/mdx/evaluate.ts","../src/blocks.ts","../src/mdx/compile.ts"],"sourcesContent":["import { evaluate } from '@mdx-js/mdx';\nimport type { ComponentType } from 'react';\nimport * as runtime from 'react/jsx-runtime';\nimport remarkFrontmatter from 'remark-frontmatter';\nimport remarkGfm from 'remark-gfm';\nimport remarkMdxFrontmatter from 'remark-mdx-frontmatter';\n\n/**\n * Evaluate MDX content string to a React component.\n *\n * This is a framework-agnostic utility for converting MDX strings into\n * executable React components. Works in any Node.js environment (Astro,\n * Next.js, Remix, etc.) at build time or server-side.\n *\n * **When to use:**\n * - Building static sites with MDX content\n * - Server-side rendering MDX as React components\n * - Need React components (not HTML strings)\n *\n * @param mdxContent - The MDX string to evaluate\n * @param options - Optional configuration\n * @param options.development - Whether to use development mode (default: false)\n * @returns Object containing Component (or null) and optional error\n *\n * @example\n * ```typescript\n * import { evaluateMDXToComponent } from '@conloca/mdx/node';\n *\n * const { Component, error } = await evaluateMDXToComponent('# Hello\\n\\nThis is **MDX**');\n * if (error) {\n * console.error('Failed to evaluate:', error);\n * } else if (Component) {\n * // Render <Component /> in your React app\n * }\n * ```\n *\n * @example\n * ```typescript\n * // In Astro pages\n * const { Component } = await evaluateMDXToComponent(mdxContent);\n * // Then render in JSX: <Component />\n * ```\n */\nexport async function evaluateMDXToComponent(\n mdxContent: string,\n options?: { development?: boolean },\n): Promise<{ Component: ComponentType | null; error?: Error }> {\n try {\n const { default: MDXComponent } = await evaluate(mdxContent, {\n ...runtime,\n remarkPlugins: [remarkFrontmatter, remarkMdxFrontmatter, remarkGfm],\n development: options?.development ?? false,\n });\n\n return { Component: MDXComponent };\n } catch (error) {\n return {\n Component: null,\n error: error instanceof Error ? error : new Error('MDX evaluation failed'),\n };\n }\n}\n","import { evaluateMDXToComponent } from './mdx/evaluate.js';\nimport type { MDXBlockEvaluationResult } from './types.js';\n\ninterface BlockLocaleSummary {\n meta?: {\n title?: string;\n };\n name?: string;\n}\n\ninterface BlockManifest {\n id: string;\n locales: Record<string, BlockLocaleSummary | undefined>;\n}\n\ninterface BlockLocalizedEntry {\n localized?: {\n meta?: {\n title?: string;\n };\n name?: string;\n content?: {\n mdx?: string;\n };\n };\n}\n\ninterface BlockAPI {\n listAllContent(filters: { kind: 'block' }): Iterable<BlockManifest>;\n getLocalized(id: string, locale: string): Promise<BlockLocalizedEntry | null>;\n}\n\n/**\n * Evaluate all MDX blocks from a compatible content API.\n *\n * Returns structured success/error results so callers can decide how to\n * surface broken blocks instead of hardcoding fallback UI in this package.\n */\nexport async function evaluateMDXBlocks(api: BlockAPI, locale: string): Promise<MDXBlockEvaluationResult[]> {\n const blocks = Array.from(api.listAllContent({ kind: 'block' }));\n\n return Promise.all(\n blocks.map(async (block) => {\n const locales = Object.keys(block.locales);\n const firstLocale = locales.length > 0 ? block.locales[locales[0]] : null;\n const manifestTitle = firstLocale?.meta?.title || firstLocale?.name || block.id;\n\n try {\n const blockLocalized = await api.getLocalized(block.id, locale);\n const blockTitle = blockLocalized?.localized?.meta?.title || blockLocalized?.localized?.name || manifestTitle;\n const mdxContent = blockLocalized?.localized?.content?.mdx;\n\n if (!mdxContent) {\n return {\n ok: false,\n id: block.id,\n title: blockTitle,\n error: new Error(`No MDX content found for block: ${block.id}`),\n };\n }\n\n const { Component: EvaluatedComponent, error } = await evaluateMDXToComponent(mdxContent);\n\n if (error || !EvaluatedComponent) {\n return {\n ok: false,\n id: block.id,\n title: blockTitle,\n error: error || new Error(`MDX evaluation failed for block: ${block.id}`),\n };\n }\n\n return {\n ok: true,\n id: block.id,\n title: blockTitle,\n Component: EvaluatedComponent,\n };\n } catch (error) {\n return {\n ok: false,\n id: block.id,\n title: manifestTitle,\n error: error instanceof Error ? error : new Error(`Failed to evaluate block: ${block.id}`),\n };\n }\n }),\n );\n}\n","import { compile as mdxCompile } from '@mdx-js/mdx';\nimport matter from 'gray-matter';\nimport remarkFrontmatter from 'remark-frontmatter';\nimport remarkGfm from 'remark-gfm';\nimport remarkMdxFrontmatter from 'remark-mdx-frontmatter';\nimport type { MDXCompileResult } from '../types.js';\n\nexport async function compileMDX(content: string): Promise<MDXCompileResult> {\n try {\n const { data: metadata } = matter(content, {});\n\n const compiled = await mdxCompile(content, {\n outputFormat: 'function-body',\n development: process.env.NODE_ENV === 'development',\n remarkPlugins: [remarkFrontmatter, remarkMdxFrontmatter, remarkGfm],\n });\n\n return {\n code: String(compiled.value),\n metadata: metadata as Record<string, unknown>,\n };\n } catch (error) {\n if (error instanceof Error) {\n const enhancedError = new Error(`MDX compilation failed: ${error.message}`);\n enhancedError.stack = error.stack;\n throw enhancedError;\n }\n\n throw error;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2CA,eAAsB,uBACpB,YACA,SAC6D;CAC7D,IAAI;EACF,MAAM,EAAE,SAAS,iBAAiB,MAAM,SAAS,YAAY;GAC3D,GAAG;GACH,eAAe;IAAC;IAAmB;IAAsB;GAAS;GAClE,aAAa,SAAS,eAAe;EACvC,CAAC;EAED,OAAO,EAAE,WAAW,aAAa;CACnC,SAAS,OAAO;EACd,OAAO;GACL,WAAW;GACX,OAAO,iBAAiB,QAAQ,wBAAQ,IAAI,MAAM,uBAAuB;EAC3E;CACF;AACF;;;;;;;;;ACvBA,eAAsB,kBAAkB,KAAe,QAAqD;CAC1G,MAAM,SAAS,MAAM,KAAK,IAAI,eAAe,EAAE,MAAM,QAAQ,CAAC,CAAC;CAE/D,OAAO,QAAQ,IACb,OAAO,IAAI,OAAO,UAAU;EAC1B,MAAM,UAAU,OAAO,KAAK,MAAM,OAAO;EACzC,MAAM,cAAc,QAAQ,SAAS,IAAI,MAAM,QAAQ,QAAQ,MAAM;EACrE,MAAM,gBAAgB,aAAa,MAAM,SAAS,aAAa,QAAQ,MAAM;EAE7E,IAAI;GACF,MAAM,iBAAiB,MAAM,IAAI,aAAa,MAAM,IAAI,MAAM;GAC9D,MAAM,aAAa,gBAAgB,WAAW,MAAM,SAAS,gBAAgB,WAAW,QAAQ;GAChG,MAAM,aAAa,gBAAgB,WAAW,SAAS;GAEvD,IAAI,CAAC,YACH,OAAO;IACL,IAAI;IACJ,IAAI,MAAM;IACV,OAAO;IACP,uBAAO,IAAI,MAAM,mCAAmC,MAAM,IAAI;GAChE;GAGF,MAAM,EAAE,WAAW,oBAAoB,UAAU,MAAM,uBAAuB,UAAU;GAExF,IAAI,SAAS,CAAC,oBACZ,OAAO;IACL,IAAI;IACJ,IAAI,MAAM;IACV,OAAO;IACP,OAAO,yBAAS,IAAI,MAAM,oCAAoC,MAAM,IAAI;GAC1E;GAGF,OAAO;IACL,IAAI;IACJ,IAAI,MAAM;IACV,OAAO;IACP,WAAW;GACb;EACF,SAAS,OAAO;GACd,OAAO;IACL,IAAI;IACJ,IAAI,MAAM;IACV,OAAO;IACP,OAAO,iBAAiB,QAAQ,wBAAQ,IAAI,MAAM,6BAA6B,MAAM,IAAI;GAC3F;EACF;CACF,CAAC,CACH;AACF;;;ACjFA,eAAsB,WAAW,SAA4C;CAC3E,IAAI;EACF,MAAM,EAAE,MAAM,aAAa,OAAO,SAAS,CAAC,CAAC;EAE7C,MAAM,WAAW,MAAMA,QAAW,SAAS;GACzC,cAAc;GACd,aAAa,QAAQ,IAAI,aAAa;GACtC,eAAe;IAAC;IAAmB;IAAsB;GAAS;EACpE,CAAC;EAED,OAAO;GACL,MAAM,OAAO,SAAS,KAAK;GACjB;EACZ;CACF,SAAS,OAAO;EACd,IAAI,iBAAiB,OAAO;GAC1B,MAAM,gCAAgB,IAAI,MAAM,2BAA2B,MAAM,SAAS;GAC1E,cAAc,QAAQ,MAAM;GAC5B,MAAM;EACR;EAEA,MAAM;CACR;AACF"}
package/dist/style.css DELETED
@@ -1,88 +0,0 @@
1
- .mdxeditor-toolbar-wrap {
2
- flex-wrap: wrap;
3
- flex-shrink: 0;
4
- row-gap: 4px;
5
- }
6
-
7
- .mdxeditor {
8
- flex-direction: column;
9
- height: 100%;
10
- min-height: 0;
11
- display: flex;
12
- }
13
-
14
- .mdxeditor-diff-source-wrapper {
15
- flex: 1;
16
- min-height: 0;
17
- overflow-y: auto;
18
- }
19
-
20
- .mdxeditor-toolbar-wrap [aria-label="Block type"] > span:first-child:empty:before {
21
- content: "Block";
22
- opacity: .6;
23
- }
24
-
25
- @media (width <= 640px) {
26
- .mdxeditor-toolbar-wrap {
27
- gap: 2px;
28
- }
29
-
30
- .mdxeditor-toolbar-wrap button {
31
- padding-inline: 4px;
32
- }
33
-
34
- .mdxeditor-toolbar-wrap [data-orientation="vertical"] {
35
- display: none;
36
- }
37
-
38
- .mdxeditor-toolbar-wrap > div:first-child {
39
- flex-wrap: wrap;
40
- row-gap: 2px;
41
- }
42
- }
43
-
44
- [class*="_contentEditable_"].conloca-prose {
45
- font-family: var(--conloca-host-font-family, inherit);
46
- font-size: var(--conloca-host-font-size, inherit);
47
- font-weight: var(--conloca-host-font-weight, inherit);
48
- font-style: var(--conloca-host-font-style, inherit);
49
- line-height: var(--conloca-host-line-height, inherit);
50
- letter-spacing: var(--conloca-host-letter-spacing, inherit);
51
- color: var(--conloca-host-color, inherit);
52
- }
53
-
54
- .conloca-prose [class*="_listitem_"] {
55
- margin-block: 0;
56
- }
57
-
58
- .conloca-code-block [class*="codeMirrorWrapper"] {
59
- background: none;
60
- border: 0;
61
- border-radius: 0;
62
- margin: 0;
63
- padding: 0;
64
- position: static;
65
- }
66
-
67
- .conloca-code-block {
68
- position: relative;
69
- }
70
-
71
- .conloca-code-block__filename {
72
- all: unset;
73
- font: inherit;
74
- color: inherit;
75
- cursor: text;
76
- box-sizing: border-box;
77
- width: 100%;
78
- min-width: 0;
79
- }
80
-
81
- .conloca-code-block__filename:focus {
82
- outline-offset: 2px;
83
- outline: 1px dashed;
84
- }
85
-
86
- .conloca-code-block .cm-editor, .conloca-code-block .cm-editor .cm-scroller, .conloca-code-block .cm-editor .cm-gutters, .conloca-code-block .cm-editor .cm-content, .conloca-code-block .cm-editor .cm-line {
87
- background: none;
88
- }