@stream-mdx/react 0.4.0 → 1.0.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.
- package/CHANGELOG.md +385 -4
- package/README.md +141 -16
- package/dist/blocks-renderer-DAOBFBfi.d.ts +29 -0
- package/dist/blocks-renderer-DQEL1kJW.d.cts +29 -0
- package/dist/components/bottom-stick-scroll-area.cjs +268 -0
- package/dist/components/bottom-stick-scroll-area.d.cts +36 -0
- package/dist/components/bottom-stick-scroll-area.d.ts +36 -0
- package/dist/components/bottom-stick-scroll-area.mjs +249 -0
- package/dist/components/diff-renderer.cjs +86 -0
- package/dist/components/diff-renderer.d.cts +11 -0
- package/dist/components/diff-renderer.d.ts +11 -0
- package/dist/components/diff-renderer.mjs +66 -0
- package/dist/components/index.cjs +2879 -1295
- package/dist/components/index.d.cts +9 -2
- package/dist/components/index.d.ts +9 -2
- package/dist/components/index.mjs +2842 -1277
- package/dist/components/katex-math.cjs +220 -0
- package/dist/components/katex-math.d.cts +10 -0
- package/dist/components/katex-math.d.ts +10 -0
- package/dist/components/katex-math.mjs +188 -0
- package/dist/contexts/math-tracker.cjs +240 -521
- package/dist/contexts/math-tracker.mjs +235 -513
- package/dist/index-Cmne1yUK.d.cts +723 -0
- package/dist/index-D7dyyu3q.d.ts +723 -0
- package/dist/index.cjs +13180 -5640
- package/dist/index.d.cts +72 -40
- package/dist/index.d.ts +72 -40
- package/dist/index.mjs +12587 -5038
- package/dist/math/display-wrapper.cjs +7 -15
- package/dist/math/display-wrapper.d.cts +2 -2
- package/dist/math/display-wrapper.d.ts +2 -2
- package/dist/math/display-wrapper.mjs +2 -6
- package/dist/node-views-Bpc6Gkgl.d.cts +13 -0
- package/dist/node-views-DpnYdaAS.d.ts +13 -0
- package/dist/renderer/hooks.cjs +35 -20
- package/dist/renderer/hooks.d.cts +22 -1
- package/dist/renderer/hooks.d.ts +22 -1
- package/dist/renderer/hooks.mjs +27 -12
- package/dist/renderer/patch-batching.cjs +7 -8
- package/dist/renderer/patch-batching.d.cts +1 -1
- package/dist/renderer/patch-batching.d.ts +1 -1
- package/dist/renderer/patch-batching.mjs +2 -1
- package/dist/renderer/patch-coalescing.cjs +5 -8
- package/dist/renderer/patch-commit-scheduler.cjs +160 -326
- package/dist/renderer/patch-commit-scheduler.d.cts +28 -4
- package/dist/renderer/patch-commit-scheduler.d.ts +28 -4
- package/dist/renderer/patch-commit-scheduler.mjs +157 -318
- package/dist/renderer/store.cjs +3847 -1099
- package/dist/renderer/store.d.cts +111 -3
- package/dist/renderer/store.d.ts +111 -3
- package/dist/renderer/store.mjs +3847 -1085
- package/dist/renderer/virtualized-code.cjs +415 -71
- package/dist/renderer/virtualized-code.d.cts +24 -23
- package/dist/renderer/virtualized-code.d.ts +24 -23
- package/dist/renderer/virtualized-code.mjs +409 -62
- package/dist/renderer.cjs +10939 -3974
- package/dist/renderer.d.cts +100 -29
- package/dist/renderer.d.ts +100 -29
- package/dist/renderer.mjs +10711 -3697
- package/dist/server-regions-CPLHGli0.d.cts +32 -0
- package/dist/server-regions-mUhyoKi7.d.ts +32 -0
- package/dist/server.cjs +10286 -3365
- package/dist/server.d.cts +17 -247
- package/dist/server.d.ts +17 -247
- package/dist/server.mjs +10565 -3619
- package/dist/{streaming-markdown-DOc2uLiP.d.ts → streaming-markdown-yELbJxyH.d.ts} +51 -55
- package/dist/{streaming-markdown-D-JcByd9.d.cts → streaming-markdown-zVwFuaJG.d.cts} +51 -55
- package/dist/streaming-markdown.cjs +11828 -4879
- package/dist/streaming-markdown.d.cts +9 -2
- package/dist/streaming-markdown.d.ts +9 -2
- package/dist/streaming-markdown.mjs +11820 -4821
- package/dist/trusted-mdx/index.cjs +833 -0
- package/dist/trusted-mdx/index.d.cts +11 -0
- package/dist/trusted-mdx/index.d.ts +11 -0
- package/dist/trusted-mdx/index.mjs +807 -0
- package/dist/trusted-mdx/native-children-slot.cjs +45 -0
- package/dist/trusted-mdx/native-children-slot.d.cts +11 -0
- package/dist/trusted-mdx/native-children-slot.d.ts +11 -0
- package/dist/trusted-mdx/native-children-slot.mjs +24 -0
- package/dist/trusted-mdx/server.cjs +752 -0
- package/dist/trusted-mdx/server.d.cts +24 -0
- package/dist/trusted-mdx/server.d.ts +24 -0
- package/dist/trusted-mdx/server.mjs +724 -0
- package/dist/trusted-mdx-contract-ElKpkDI5.d.cts +113 -0
- package/dist/trusted-mdx-contract-ElKpkDI5.d.ts +113 -0
- package/dist/utils/inline-html.cjs +246 -147
- package/dist/utils/inline-html.d.cts +39 -6
- package/dist/utils/inline-html.d.ts +39 -6
- package/dist/utils/inline-html.mjs +237 -134
- package/package.json +52 -18
- package/shadcn/README.md +28 -0
- package/shadcn/bottom-stick-scroll-area.tsx +358 -0
- package/dist/index-D2MYusAM.d.cts +0 -248
- package/dist/index-D2MYusAM.d.ts +0 -248
- package/dist/mdx-client.cjs +0 -408
- package/dist/mdx-client.d.cts +0 -113
- package/dist/mdx-client.d.ts +0 -113
- package/dist/mdx-client.mjs +0 -369
- package/dist/mdx-coordinator.cjs +0 -563
- package/dist/mdx-coordinator.d.cts +0 -21
- package/dist/mdx-coordinator.d.ts +0 -21
- package/dist/mdx-coordinator.mjs +0 -529
- package/dist/renderer/node-views.cjs +0 -1642
- package/dist/renderer/node-views.d.cts +0 -12
- package/dist/renderer/node-views.d.ts +0 -12
- package/dist/renderer/node-views.mjs +0 -1616
|
@@ -1,50 +1,23 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import React__default from 'react';
|
|
2
|
+
import { a1 as LinkSafetyModalProps, l as ElementFilterOptions, _ as NodePresentations, C as ContentComponentsMap, a2 as MathEngine, $ as MermaidEngine, M as MathOptions, T as TableVirtualizationOptions, b as ControlsConfig, c as ControlsComponentProps, w as AnimatedProp } from './index-D7dyyu3q.js';
|
|
3
|
+
import { PatchMetrics, FormatAnticipationConfig, CodeHighlightingMode, Block, ContentPolicy, SyntaxExtensionDescriptor, HtmlOptions, UrlTransform } from '@stream-mdx/core';
|
|
4
|
+
import { VirtualizedCodeConfig } from './renderer/virtualized-code.js';
|
|
5
|
+
import { a as TrustedMdxEngine } from './trusted-mdx-contract-ElKpkDI5.js';
|
|
6
|
+
import { FinalizeResult, AppendResult, WaitForCapacityOptions } from '@stream-mdx/protocol';
|
|
4
7
|
import { AdaptiveBudgetState, PatchFlushResult } from './renderer/patch-commit-scheduler.js';
|
|
5
8
|
import { RendererStore } from './renderer/store.js';
|
|
6
|
-
|
|
7
|
-
type MdxHydrationStrategy = "immediate" | "staggered" | "visible";
|
|
8
|
-
type MdxHydrationOptions = {
|
|
9
|
-
strategy?: MdxHydrationStrategy;
|
|
10
|
-
maxConcurrent?: number;
|
|
11
|
-
delayMs?: number;
|
|
12
|
-
rootMargin?: string;
|
|
13
|
-
idleTimeoutMs?: number;
|
|
14
|
-
debounceMs?: number;
|
|
15
|
-
};
|
|
9
|
+
import { CodeEngine } from '@stream-mdx/worker/engine';
|
|
16
10
|
|
|
17
11
|
type DeferredRenderConfig = {
|
|
18
12
|
rootMargin?: string;
|
|
19
13
|
idleTimeoutMs?: number;
|
|
20
14
|
debounceMs?: number;
|
|
21
15
|
};
|
|
22
|
-
declare const DeferredRenderContext:
|
|
16
|
+
declare const DeferredRenderContext: React__default.Context<DeferredRenderConfig | null>;
|
|
23
17
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
error: number;
|
|
28
|
-
pending: number;
|
|
29
|
-
avgPrefetchMs: number | null;
|
|
30
|
-
p95PrefetchMs: number | null;
|
|
31
|
-
maxPrefetchMs: number | null;
|
|
32
|
-
lastPrefetchMs: number | null;
|
|
33
|
-
};
|
|
34
|
-
type MdxHydrationSummary = {
|
|
35
|
-
compiled: number;
|
|
36
|
-
hydrated: number;
|
|
37
|
-
error: number;
|
|
38
|
-
avgHydrationMs: number | null;
|
|
39
|
-
p95HydrationMs: number | null;
|
|
40
|
-
maxHydrationMs: number | null;
|
|
41
|
-
lastHydrationMs: number | null;
|
|
42
|
-
longTaskTotalMs: number | null;
|
|
43
|
-
longTaskCount: number | null;
|
|
44
|
-
p95LongTaskMs: number | null;
|
|
45
|
-
maxLongTaskMs: number | null;
|
|
46
|
-
prefetch?: MdxPrefetchSummary | null;
|
|
47
|
-
};
|
|
18
|
+
declare class EngineCompatibilityError extends Error {
|
|
19
|
+
constructor(message?: string);
|
|
20
|
+
}
|
|
48
21
|
|
|
49
22
|
interface StreamingSchedulerOptions {
|
|
50
23
|
frameBudgetMs?: number;
|
|
@@ -55,6 +28,8 @@ interface StreamingSchedulerOptions {
|
|
|
55
28
|
urgentQueueThreshold?: number;
|
|
56
29
|
batch?: "rAF" | "microtask" | "timeout";
|
|
57
30
|
historyLimit?: number;
|
|
31
|
+
startupMicrotaskFlushes?: number;
|
|
32
|
+
adaptiveBudgeting?: boolean;
|
|
58
33
|
adaptiveSwitch?: boolean;
|
|
59
34
|
adaptiveQueueThreshold?: number;
|
|
60
35
|
}
|
|
@@ -71,6 +46,10 @@ interface StreamingFeatureFlags {
|
|
|
71
46
|
liveTokenization?: boolean;
|
|
72
47
|
emitHighlightTokens?: boolean;
|
|
73
48
|
emitDiffBlocks?: boolean;
|
|
49
|
+
themes?: {
|
|
50
|
+
light: string;
|
|
51
|
+
dark: string;
|
|
52
|
+
};
|
|
74
53
|
}
|
|
75
54
|
/**
|
|
76
55
|
* Metrics emitted after each flush (high-priority + low-priority batches).
|
|
@@ -105,16 +84,14 @@ interface RendererStateSnapshot {
|
|
|
105
84
|
rendererVersion: number;
|
|
106
85
|
store: RendererStore;
|
|
107
86
|
lastMetrics: RendererMetrics | null;
|
|
108
|
-
mdxHydration?: MdxHydrationSummary & {
|
|
109
|
-
pending: number;
|
|
110
|
-
};
|
|
111
87
|
}
|
|
112
88
|
interface StreamingMarkdownHandle {
|
|
113
89
|
pause(): void;
|
|
114
90
|
resume(): void;
|
|
115
91
|
restart(): void;
|
|
116
|
-
finalize():
|
|
117
|
-
append(text: string):
|
|
92
|
+
finalize(): Promise<FinalizeResult>;
|
|
93
|
+
append(text: string): AppendResult;
|
|
94
|
+
waitForCapacity(options: WaitForCapacityOptions): Promise<void>;
|
|
118
95
|
setCredits(value: number): void;
|
|
119
96
|
flushPending(): PatchFlushResult | null;
|
|
120
97
|
waitForIdle(): Promise<void>;
|
|
@@ -127,31 +104,50 @@ type LinkSafetyCheck = (url: string) => boolean | Promise<boolean>;
|
|
|
127
104
|
type LinkSafetyConfig = {
|
|
128
105
|
enabled?: boolean;
|
|
129
106
|
onLinkCheck?: LinkSafetyCheck;
|
|
130
|
-
renderModal?: (props: LinkSafetyModalProps) =>
|
|
107
|
+
renderModal?: (props: LinkSafetyModalProps) => React__default.ReactNode;
|
|
131
108
|
};
|
|
132
|
-
|
|
109
|
+
type MarkdownEngineMode = "auto" | "main" | "worker";
|
|
110
|
+
interface StreamingMarkdownProps extends ElementFilterOptions {
|
|
133
111
|
text?: string;
|
|
134
112
|
stream?: AsyncIterable<string>;
|
|
135
113
|
worker?: Worker | URL | (() => Worker) | string;
|
|
114
|
+
engine?: MarkdownEngineMode;
|
|
136
115
|
managedWorker?: boolean;
|
|
137
116
|
prewarmLangs?: string[];
|
|
138
117
|
features?: StreamingFeatureFlags;
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
118
|
+
themes?: {
|
|
119
|
+
light: string;
|
|
120
|
+
dark: string;
|
|
121
|
+
};
|
|
122
|
+
colorScheme?: "light" | "dark" | "system";
|
|
123
|
+
components?: NodePresentations;
|
|
144
124
|
scheduling?: StreamingSchedulerOptions;
|
|
145
|
-
|
|
146
|
-
|
|
125
|
+
contentPolicy?: ContentPolicy;
|
|
126
|
+
contentComponents?: ContentComponentsMap;
|
|
127
|
+
engines?: {
|
|
128
|
+
code?: CodeEngine;
|
|
129
|
+
math?: MathEngine;
|
|
130
|
+
mermaid?: MermaidEngine;
|
|
131
|
+
mdx?: TrustedMdxEngine;
|
|
132
|
+
};
|
|
147
133
|
onMetrics?: (metrics: RendererMetrics) => void;
|
|
148
134
|
onError?: (error: Error) => void;
|
|
149
135
|
className?: string;
|
|
150
|
-
style?:
|
|
136
|
+
style?: React__default.CSSProperties;
|
|
151
137
|
caret?: StreamingCaret;
|
|
152
138
|
linkSafety?: LinkSafetyConfig;
|
|
139
|
+
mathOptions?: MathOptions;
|
|
153
140
|
deferHeavyBlocks?: boolean | DeferredRenderConfig;
|
|
141
|
+
syntax?: SyntaxExtensionDescriptor;
|
|
142
|
+
html?: HtmlOptions;
|
|
143
|
+
tableVirtualization?: TableVirtualizationOptions;
|
|
144
|
+
codeVirtualization?: Partial<VirtualizedCodeConfig>;
|
|
145
|
+
urlTransform?: UrlTransform;
|
|
146
|
+
controls?: ControlsConfig;
|
|
147
|
+
controlsComponent?: React__default.ComponentType<ControlsComponentProps>;
|
|
148
|
+
animated?: AnimatedProp;
|
|
149
|
+
statusMessage?: string;
|
|
154
150
|
}
|
|
155
|
-
declare const StreamingMarkdown:
|
|
151
|
+
declare const StreamingMarkdown: React__default.ForwardRefExoticComponent<StreamingMarkdownProps & React__default.RefAttributes<StreamingMarkdownHandle>>;
|
|
156
152
|
|
|
157
|
-
export { type DeferredRenderConfig as D, type LinkSafetyCheck as L, type
|
|
153
|
+
export { type DeferredRenderConfig as D, EngineCompatibilityError as E, type LinkSafetyCheck as L, type MarkdownEngineMode as M, type RendererMetrics as R, type StreamingSchedulerOptions as S, DeferredRenderContext as a, type StreamingFeatureFlags as b, type RendererStateSnapshot as c, type StreamingMarkdownHandle as d, type StreamingCaret as e, type LinkSafetyConfig as f, type StreamingMarkdownProps as g, StreamingMarkdown as h };
|
|
@@ -1,50 +1,23 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import React__default from 'react';
|
|
2
|
+
import { a1 as LinkSafetyModalProps, l as ElementFilterOptions, _ as NodePresentations, C as ContentComponentsMap, a2 as MathEngine, $ as MermaidEngine, M as MathOptions, T as TableVirtualizationOptions, b as ControlsConfig, c as ControlsComponentProps, w as AnimatedProp } from './index-Cmne1yUK.cjs';
|
|
3
|
+
import { PatchMetrics, FormatAnticipationConfig, CodeHighlightingMode, Block, ContentPolicy, SyntaxExtensionDescriptor, HtmlOptions, UrlTransform } from '@stream-mdx/core';
|
|
4
|
+
import { VirtualizedCodeConfig } from './renderer/virtualized-code.cjs';
|
|
5
|
+
import { a as TrustedMdxEngine } from './trusted-mdx-contract-ElKpkDI5.cjs';
|
|
6
|
+
import { FinalizeResult, AppendResult, WaitForCapacityOptions } from '@stream-mdx/protocol';
|
|
4
7
|
import { AdaptiveBudgetState, PatchFlushResult } from './renderer/patch-commit-scheduler.cjs';
|
|
5
8
|
import { RendererStore } from './renderer/store.cjs';
|
|
6
|
-
|
|
7
|
-
type MdxHydrationStrategy = "immediate" | "staggered" | "visible";
|
|
8
|
-
type MdxHydrationOptions = {
|
|
9
|
-
strategy?: MdxHydrationStrategy;
|
|
10
|
-
maxConcurrent?: number;
|
|
11
|
-
delayMs?: number;
|
|
12
|
-
rootMargin?: string;
|
|
13
|
-
idleTimeoutMs?: number;
|
|
14
|
-
debounceMs?: number;
|
|
15
|
-
};
|
|
9
|
+
import { CodeEngine } from '@stream-mdx/worker/engine';
|
|
16
10
|
|
|
17
11
|
type DeferredRenderConfig = {
|
|
18
12
|
rootMargin?: string;
|
|
19
13
|
idleTimeoutMs?: number;
|
|
20
14
|
debounceMs?: number;
|
|
21
15
|
};
|
|
22
|
-
declare const DeferredRenderContext:
|
|
16
|
+
declare const DeferredRenderContext: React__default.Context<DeferredRenderConfig | null>;
|
|
23
17
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
error: number;
|
|
28
|
-
pending: number;
|
|
29
|
-
avgPrefetchMs: number | null;
|
|
30
|
-
p95PrefetchMs: number | null;
|
|
31
|
-
maxPrefetchMs: number | null;
|
|
32
|
-
lastPrefetchMs: number | null;
|
|
33
|
-
};
|
|
34
|
-
type MdxHydrationSummary = {
|
|
35
|
-
compiled: number;
|
|
36
|
-
hydrated: number;
|
|
37
|
-
error: number;
|
|
38
|
-
avgHydrationMs: number | null;
|
|
39
|
-
p95HydrationMs: number | null;
|
|
40
|
-
maxHydrationMs: number | null;
|
|
41
|
-
lastHydrationMs: number | null;
|
|
42
|
-
longTaskTotalMs: number | null;
|
|
43
|
-
longTaskCount: number | null;
|
|
44
|
-
p95LongTaskMs: number | null;
|
|
45
|
-
maxLongTaskMs: number | null;
|
|
46
|
-
prefetch?: MdxPrefetchSummary | null;
|
|
47
|
-
};
|
|
18
|
+
declare class EngineCompatibilityError extends Error {
|
|
19
|
+
constructor(message?: string);
|
|
20
|
+
}
|
|
48
21
|
|
|
49
22
|
interface StreamingSchedulerOptions {
|
|
50
23
|
frameBudgetMs?: number;
|
|
@@ -55,6 +28,8 @@ interface StreamingSchedulerOptions {
|
|
|
55
28
|
urgentQueueThreshold?: number;
|
|
56
29
|
batch?: "rAF" | "microtask" | "timeout";
|
|
57
30
|
historyLimit?: number;
|
|
31
|
+
startupMicrotaskFlushes?: number;
|
|
32
|
+
adaptiveBudgeting?: boolean;
|
|
58
33
|
adaptiveSwitch?: boolean;
|
|
59
34
|
adaptiveQueueThreshold?: number;
|
|
60
35
|
}
|
|
@@ -71,6 +46,10 @@ interface StreamingFeatureFlags {
|
|
|
71
46
|
liveTokenization?: boolean;
|
|
72
47
|
emitHighlightTokens?: boolean;
|
|
73
48
|
emitDiffBlocks?: boolean;
|
|
49
|
+
themes?: {
|
|
50
|
+
light: string;
|
|
51
|
+
dark: string;
|
|
52
|
+
};
|
|
74
53
|
}
|
|
75
54
|
/**
|
|
76
55
|
* Metrics emitted after each flush (high-priority + low-priority batches).
|
|
@@ -105,16 +84,14 @@ interface RendererStateSnapshot {
|
|
|
105
84
|
rendererVersion: number;
|
|
106
85
|
store: RendererStore;
|
|
107
86
|
lastMetrics: RendererMetrics | null;
|
|
108
|
-
mdxHydration?: MdxHydrationSummary & {
|
|
109
|
-
pending: number;
|
|
110
|
-
};
|
|
111
87
|
}
|
|
112
88
|
interface StreamingMarkdownHandle {
|
|
113
89
|
pause(): void;
|
|
114
90
|
resume(): void;
|
|
115
91
|
restart(): void;
|
|
116
|
-
finalize():
|
|
117
|
-
append(text: string):
|
|
92
|
+
finalize(): Promise<FinalizeResult>;
|
|
93
|
+
append(text: string): AppendResult;
|
|
94
|
+
waitForCapacity(options: WaitForCapacityOptions): Promise<void>;
|
|
118
95
|
setCredits(value: number): void;
|
|
119
96
|
flushPending(): PatchFlushResult | null;
|
|
120
97
|
waitForIdle(): Promise<void>;
|
|
@@ -127,31 +104,50 @@ type LinkSafetyCheck = (url: string) => boolean | Promise<boolean>;
|
|
|
127
104
|
type LinkSafetyConfig = {
|
|
128
105
|
enabled?: boolean;
|
|
129
106
|
onLinkCheck?: LinkSafetyCheck;
|
|
130
|
-
renderModal?: (props: LinkSafetyModalProps) =>
|
|
107
|
+
renderModal?: (props: LinkSafetyModalProps) => React__default.ReactNode;
|
|
131
108
|
};
|
|
132
|
-
|
|
109
|
+
type MarkdownEngineMode = "auto" | "main" | "worker";
|
|
110
|
+
interface StreamingMarkdownProps extends ElementFilterOptions {
|
|
133
111
|
text?: string;
|
|
134
112
|
stream?: AsyncIterable<string>;
|
|
135
113
|
worker?: Worker | URL | (() => Worker) | string;
|
|
114
|
+
engine?: MarkdownEngineMode;
|
|
136
115
|
managedWorker?: boolean;
|
|
137
116
|
prewarmLangs?: string[];
|
|
138
117
|
features?: StreamingFeatureFlags;
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
118
|
+
themes?: {
|
|
119
|
+
light: string;
|
|
120
|
+
dark: string;
|
|
121
|
+
};
|
|
122
|
+
colorScheme?: "light" | "dark" | "system";
|
|
123
|
+
components?: NodePresentations;
|
|
144
124
|
scheduling?: StreamingSchedulerOptions;
|
|
145
|
-
|
|
146
|
-
|
|
125
|
+
contentPolicy?: ContentPolicy;
|
|
126
|
+
contentComponents?: ContentComponentsMap;
|
|
127
|
+
engines?: {
|
|
128
|
+
code?: CodeEngine;
|
|
129
|
+
math?: MathEngine;
|
|
130
|
+
mermaid?: MermaidEngine;
|
|
131
|
+
mdx?: TrustedMdxEngine;
|
|
132
|
+
};
|
|
147
133
|
onMetrics?: (metrics: RendererMetrics) => void;
|
|
148
134
|
onError?: (error: Error) => void;
|
|
149
135
|
className?: string;
|
|
150
|
-
style?:
|
|
136
|
+
style?: React__default.CSSProperties;
|
|
151
137
|
caret?: StreamingCaret;
|
|
152
138
|
linkSafety?: LinkSafetyConfig;
|
|
139
|
+
mathOptions?: MathOptions;
|
|
153
140
|
deferHeavyBlocks?: boolean | DeferredRenderConfig;
|
|
141
|
+
syntax?: SyntaxExtensionDescriptor;
|
|
142
|
+
html?: HtmlOptions;
|
|
143
|
+
tableVirtualization?: TableVirtualizationOptions;
|
|
144
|
+
codeVirtualization?: Partial<VirtualizedCodeConfig>;
|
|
145
|
+
urlTransform?: UrlTransform;
|
|
146
|
+
controls?: ControlsConfig;
|
|
147
|
+
controlsComponent?: React__default.ComponentType<ControlsComponentProps>;
|
|
148
|
+
animated?: AnimatedProp;
|
|
149
|
+
statusMessage?: string;
|
|
154
150
|
}
|
|
155
|
-
declare const StreamingMarkdown:
|
|
151
|
+
declare const StreamingMarkdown: React__default.ForwardRefExoticComponent<StreamingMarkdownProps & React__default.RefAttributes<StreamingMarkdownHandle>>;
|
|
156
152
|
|
|
157
|
-
export { type DeferredRenderConfig as D, type LinkSafetyCheck as L, type
|
|
153
|
+
export { type DeferredRenderConfig as D, EngineCompatibilityError as E, type LinkSafetyCheck as L, type MarkdownEngineMode as M, type RendererMetrics as R, type StreamingSchedulerOptions as S, DeferredRenderContext as a, type StreamingFeatureFlags as b, type RendererStateSnapshot as c, type StreamingMarkdownHandle as d, type StreamingCaret as e, type LinkSafetyConfig as f, type StreamingMarkdownProps as g, StreamingMarkdown as h };
|