markstream-react 0.1.0-beta.3 → 2.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/dist/tailwind.cjs CHANGED
@@ -1,4 +1,4 @@
1
- const safeList = `use client react stream-markdown-parser string cannot delete global call clearGlobalCustomComponents checkbox-node checkbox checkbox-input blockquote-node auto emoji-node note is-dark data-index-key headerId admonition-header admonition-icon admonition-title admonition-toggle aria-expanded aria-controls collapsed admonition-content aria-labelledby clsx heading-node font-semibold object emphasis-node dl definition-list indexKey mb-4 dt definition-term ctx renderNode ?? definition dd definition-desc ml-4 dependency is not install it to enable smooth footnote-reference handleScroll footnote-link cursor-pointer html-block-node safe escape html-block html-block-node__placeholder html-block-node__placeholder-bar w-4/5 w-2/3 setHostEl shouldRender useDynamic reactNodes mark highlight-node footnote-node flex text-sm leading-relaxed border-t border-[var(--footnote-border,#eaecef)] pt-2 flex-1 footnote-anchor hover:underline ↩︎ list-item pl-1.5 my-2 valueAttr children hard-break primary fallback failed is-loaded lazy eager async image image-node__placeholder image-node__spinner image-node__placeholder-text image… placeholder image-node__error currentColor load number ease-in-out typeof infinite node.title top link-loading inline-flex items-baseline gap-1.5 link-text-wrapper relative leading-[normal] link-text text link-loading-indicator link-node aria-label noopener noreferrer list-node my-5 pl-[calc(13/8*1em)] list-decimal list-disc max-lg:my-[calc(4/3*1em)] max-lg:pl-[calc(14/9*1em)] list unknown-node text-gray-500 italic node insert-node href name xlink:href markstream-d2-root-svg window.requestAnimationFrame instance.render instance missing render returned empty d2-block my-4 rounded-lg border overflow-hidden shadow-sm border-gray-700/30 bg-gray-900 text-gray-100 border-gray-200 bg-white text-gray-900 d2-block-header justify-between items-center px-4 py-2.5 border-b border-gray-400/5 gap-x-2 font-medium font-mono gap-x-1 rounded-md p-0.5 bg-gray-700 bg-gray-100 mode-btn px-2 py-1 text-xs rounded !showSource is-active showSource d2-action-btn p-2 transition-colors hover:bg-[var(--vscode-editor-selectionBackground)] copying w-3 h-3 none round aria-pressed m9 bodyRef d2-block-body bodyStyle !hasPreview d2-source py-4 d2-code d2-error mt-2 d2-render d2-svg pb-3 inline-code inline text-[85%] px-1 py-0.5 bg-[hsl(var(--secondary))] whitespace-normal break-words max-w-full text-node-stream-delta text-node-stream-delta--a text-node-stream-delta--b markstream-core plaintext data-ssr-fallback aria-busy normalizedLanguage block data-language no html_block node.type html_inline boolean mermaid infographic d2 language d2lang scroll pre-wrap configuredShowLineNumbers disableLineNumbers whitespace-pre-wrap text-node-center paragraph-node renderNodeProp paragraph child.type classAttr node.cite value void right text-right center text-center text-left table-node-wrapper table-node--loading border-[var(--table-border,#cbd5e1)] p-[calc(4/7*1em)] rowIdx bodyRows.length table-node__loading status polite table-node__spinner sr-only isOpen strong-node emphasis strikethrough-node strikethrough highlight insert subscript-node subscript superscript-node superscript thematic-break-node cssVars image-node__img code-block-node code-block mermaid-block-node d2-block-node infographic-block-node math-block overflow-x-auto min-h-[40px] node.content $$ math-inline-wrapper math-inline reference-node bg-[hsl(var(--muted))] px-1.5 mx-0.5 hover:bg-[hsl(var(--secondary))] data-reference-id customComponents html-inline vmr-container code_block text_special heading list_item definition_list footnote footnote_reference footnote_anchor admonition hardbreak inline_code checkbox_input emoji thematic_break math_inline math_block reference vmr_container label_open label_close server-renderer markdown-renderer dark data-custom-id node-slot data-node-index data-node-type node-content react-dom w-4 h-4 flex-shrink-0 library text-red-500 p-4">Failed instanceof error.message error hidden keydown transform ease fullscreen touches text-gray-400 hover:bg-gray-700 hover:text-gray-200 text-gray-600 hover:bg-gray-200 hover:text-gray-700 source hasPreview preview pending is-rendering bg-gray-800 bg-gray-50 truncate px-2.5 bg-gray-600 text-gray-200 text-gray-700 m16 isCollapsed opacity-50 cursor-not-allowed m7 m14 text-gray-300 baseCode absolute top-2 right-2 z-10 gap-2 backdrop-blur infographic-preview min-h-[360px] transition-all duration-100 inset-0 cursor-grab isDragging containerRef w-full justify-center min-h-full markstream-react fixed z-50 bg-black/70 p-4 closeModal dialog h-full max-h-full shadow-lg top-6 right-6 !isDragging cursor-grabbing next next.type window.requestIdleCallback [data-node-index] node-spacer virtualized fade-node typewriter-node node-placeholder typewriterCursorRef typewriter-cursor [data-node-type="code_block"] [data-node-type="admonition"] [data-node-type="table"] [data-node-type="math_block"] [data-node-type="html_block"] [data-node-type="image"] performance [markstream-react][perf] [data-stream-diffs-state] theme themes themeType languages stream disableFileHeader onThemeChange renderCustomHeader renderHeaderMetadata renderHeaderPrefix wrap split line-info night moon black dracula mocha frappe macchiato palenight ocean poimandres monokai laserwave tokyo slack-dark rose-pine github-dark material-theme one-dark catppuccin-mocha catppuccin-frappe catppuccin-macchiato light latte dawn lotus transparent marker diff important max-height visible height onDidUpdateDiff onDidContentSizeChange onDidLayoutChange window.MutationObserver childList record.type attributes class vitesse-dark vitesse-light unified node.code fontSize lineHeight maxHeight paddingBottom paddingTop tabSize resolvedRuntimeOptions.overflow nextOptions.unsafeCSS [data-file] [data-diff] helpers.cleanupEditor canonicalLanguage single window.cancelAnimationFrame clientX navigator.clipboard navigator.clipboard.writeText code-block-container is-diff is-plain-text code-block-header code-header-main icon-slot code-header-copy min-w-0 code-header-title code-header-caption code-header-actions code-action-btn action-icon copied evenodd code-block-body--collapsed code-block-body--expanded code-fallback-plain m-0 code-editor-layer code-height-placeholder editorReady aria-hidden code-editor-fallback-surface code-loading-placeholder loading-skeleton skeleton-line short loose strict viewBox gantt open-modal [data-mermaid-wrapper] mermaid-action-btn toggle-mode common.zoomIn common.zoomOut common.resetZoom transition-[height] duration-150 ease-out data-mermaid-wrapper mermaid-loading mermaid-spinner diagram… mermaid-block-header space-x-2 space-x-1 common.preview common.source common.export mermaid-error hasRenderedOnce mermaid-block modeContainerRef mermaid-modal-overlay mermaid-modal-panel mermaid-modal-header mermaid-modal-title mermaid-modal-close mermaid-modal-body modalContentRef mermaid-modal-content available default abort timed out hr-node thematic-break containerClass text-node pointermove pointerup pointercancel my-8 table-node colgroup table-node__resize-handle event.key in zoom javascript typescript go python ruby shell powershell plain cpp csharp objectivec objectivecpp yaml markdown rust kotlin java cs php sql zsh objective-c objective-cpp window.matchMedia ms-tooltip z-[9999] inline-block text-base py-2 px-3 shadow-md whitespace-nowrap pointer-events-none tooltip-element text-white border-gray-700 tooltip tag_open token.type self_closing child key ref className ms-html tag_close parse dynamic template html-inline-node html-inline-node--loading [markstream-react] htmlPreviewSandbox contains both allow-scripts and this only fully trusted content served an isolated en utf-8 viewport content="width=device-width initial-scale=1 html-preview-frame__backdrop--dark html-preview-frame--dark html-preview-frame__header html-preview-frame__title html-preview-frame__dot html-preview-frame__label html-preview-frame__close--dark html-preview-frame__iframe no-referrer about:blank [mermaidWorkerClient] messageerror cleared worker inject via busy canParse findPrefix npm development process [katexWorkerClient] init cache-hit timeout waiting slot thinking htmlFor sequencediagram classdiagram kind statediagram erdiagram flowchart graph prototype constructor hunk !options.preserveBlankKind context removed added markstream-pre__diff-pane--inline original markstream-pre__diff-pane--original modified markstream-pre__diff-pane--modified ui-monospace monospace fontFamily markstream-pre--line-numbers markstream-pre--diff-preview markstream-pre--diff-inline showLineNumbers markstream-pre__diff-code line.empty markstream-pre__diff-line--empty markstream-pre__diff-rail markstream-pre__diff-number markstream-pre__diff-content markstream-pre__diff-content-inner markstream-pre__line-numbers markstream-pre__line-numbers-text markstream-pre__code normalizedType katex mathRef rendering math-rendering role aria-describedby document math-inline--hidden math-inline__loading math-inline__spinner value?.useMonaco stream-diffs/markstream globalThis.requestAnimationFrame globalThis.cancelAnimationFrame module did expected °C`;
1
+ const safeList = `use client react stream-markdown-parser string cannot delete global call clearGlobalCustomComponents note is-dark data-index-key headerId admonition-header admonition-icon admonition-title admonition-toggle aria-expanded aria-controls collapsed admonition-content aria-labelledby checkbox-node checkbox checkbox-input emoji-node smooth footnote-anchor text-sm hover:underline cursor-pointer ↩︎ clsx auto heading-node font-semibold object html-block-node safe escape html-block html-block-node__placeholder html-block-node__placeholder-bar w-4/5 w-2/3 setHostEl shouldRender useDynamic reactNodes mark highlight-node emphasis-node footnote-node flex leading-relaxed border-t border-[var(--footnote-border,#eaecef)] pt-2 flex-1 hard-break dl definition-list indexKey mb-4 dt definition-term ctx renderNode ?? definition dd definition-desc ml-4 footnote-reference handleScroll footnote-link dependency is not install it to enable blockquote-node href name xlink:href typeof markstream-d2-root-svg number window.requestAnimationFrame instance.render instance missing render returned empty top d2-block my-4 rounded-lg border overflow-hidden shadow-sm border-gray-700/30 bg-gray-900 text-gray-100 border-gray-200 bg-white text-gray-900 d2-block-header justify-between items-center px-4 py-2.5 border-b border-gray-400/5 gap-x-2 font-medium font-mono gap-x-1 rounded-md p-0.5 bg-gray-700 bg-gray-100 mode-btn px-2 py-1 text-xs rounded !showSource is-active showSource d2-action-btn p-2 transition-colors hover:bg-[var(--vscode-editor-selectionBackground)] copying w-3 h-3 none currentColor round aria-pressed m9 bodyRef d2-block-body bodyStyle !hasPreview d2-source py-4 d2-code d2-error mt-2 d2-render d2-svg pb-3 next code_block next.type window.requestIdleCallback [data-node-index] node-spacer dark virtualized data-custom-id node-slot data-node-index data-node-type fade-node typewriter-node node-placeholder typewriterCursorRef typewriter-cursor admonition math_block html_block image [data-node-type="code_block"] [data-node-type="admonition"] [data-node-type="table"] [data-node-type="math_block"] [data-node-type="html_block"] [data-node-type="image"] performance [markstream-react][perf] mermaid markdown-renderer boolean markstream-core plaintext data-ssr-fallback aria-busy normalizedLanguage block data-language no node.type html_inline infographic d2 language d2lang scroll pre-wrap configuredShowLineNumbers disableLineNumbers whitespace-pre-wrap text-node-center text paragraph-node renderNodeProp paragraph child.type classAttr node.cite children list-item pl-1.5 my-2 value void list-node my-5 pl-[calc(13/8*1em)] list-decimal list-disc max-lg:my-[calc(4/3*1em)] max-lg:pl-[calc(14/9*1em)] list right text-right center text-center text-left table-node-wrapper table-node--loading border-[var(--table-border,#cbd5e1)] p-[calc(4/7*1em)] rowIdx bodyRows.length table-node__loading status polite table-node__spinner sr-only isOpen strong-node emphasis strikethrough-node strikethrough highlight insert-node insert subscript-node subscript superscript-node superscript thematic-break-node inline-code inline text-[85%] px-1 py-0.5 bg-[hsl(var(--secondary))] whitespace-normal break-words max-w-full ease-in-out infinite node.title link-loading inline-flex items-baseline gap-1.5 cssVars link-text-wrapper relative leading-[normal] link-text link-loading-indicator link-node aria-label noopener noreferrer image-node__img is-loaded eager lazy async code-block-node code-block mermaid-block-node d2-block-node infographic-block-node math-block overflow-x-auto min-h-[40px] node.content $$ math-inline-wrapper math-inline reference-node bg-[hsl(var(--muted))] px-1.5 mx-0.5 hover:bg-[hsl(var(--secondary))] data-reference-id customComponents html-inline vmr-container unknown-node text-gray-500 italic node text_special heading list_item definition_list footnote footnote_reference footnote_anchor hardbreak inline_code checkbox_input emoji thematic_break math_inline reference vmr_container label_open label_close server-renderer node-content pointermove pointerup pointercancel my-8 table-node colgroup table-node__resize-handle text-node text-node-stream-delta text-node-stream-delta--a text-node-stream-delta--b in out zoom failed load [data-stream-diffs-state] theme themes themeType languages stream disableFileHeader onThemeChange renderCustomHeader renderHeaderMetadata renderHeaderPrefix wrap split line-info night moon black dracula mocha frappe macchiato palenight ocean poimandres monokai laserwave tokyo slack-dark rose-pine github-dark material-theme one-dark catppuccin-mocha catppuccin-frappe catppuccin-macchiato light latte dawn lotus transparent marker diff important max-height visible hidden height onDidUpdateDiff onDidContentSizeChange onDidLayoutChange window.MutationObserver childList record.type attributes class vitesse-dark vitesse-light unified node.code fontSize lineHeight maxHeight paddingBottom paddingTop tabSize resolvedRuntimeOptions.overflow nextOptions.unsafeCSS [data-file] [data-diff] helpers.cleanupEditor canonicalLanguage single window.cancelAnimationFrame clientX navigator.clipboard navigator.clipboard.writeText code-block-container is-rendering is-diff is-plain-text code-block-header code-header-main icon-slot h-4 w-4 flex-shrink-0 code-header-copy min-w-0 code-header-title truncate code-header-caption code-header-actions code-action-btn action-icon copied m14 evenodd code-block-body--collapsed code-block-body--expanded code-fallback-plain m-0 code-editor-layer code-height-placeholder editorReady aria-hidden code-editor-fallback-surface code-loading-placeholder loading-skeleton skeleton-line short valueAttr primary fallback image-node__placeholder image-node__spinner image-node__placeholder-text image… placeholder image-node__error hr-node thematic-break containerClass react-dom window.matchMedia fixed markstream-react ms-tooltip z-[9999] inline-block text-base py-2 px-3 shadow-md whitespace-nowrap pointer-events-none tooltip-element text-white border-gray-700 tooltip loose strict viewBox gantt open-modal keydown fullscreen [data-mermaid-wrapper] mermaid-action-btn text-gray-400 hover:bg-gray-700 hover:text-gray-200 text-gray-600 hover:bg-gray-200 hover:text-gray-700 toggle-mode preview absolute top-2 right-2 z-10 gap-2 backdrop-blur common.zoomIn common.zoomOut common.resetZoom min-h-[360px] transition-[height] duration-150 ease-out bg-gray-50 data-mermaid-wrapper inset-0 cursor-grab cursor-grabbing w-full justify-center min-h-full mermaid-loading mermaid-spinner diagram… mermaid-block-header bg-gray-800 space-x-2 space-x-1 px-2.5 bg-gray-600 text-gray-200 text-gray-700 common.preview source common.source m16 opacity-50 cursor-not-allowed common.export m7 text-gray-300 mermaid-error hasRenderedOnce pending mermaid-block modeContainerRef isCollapsed mermaid-modal-overlay mermaid-modal-panel dialog mermaid-modal-header mermaid-modal-title mermaid-modal-close closeModal mermaid-modal-body modalContentRef mermaid-modal-content available default abort timed library text-red-500 p-4">Failed instanceof error.message error transform ease touches hasPreview baseCode infographic-preview transition-all duration-100 isDragging containerRef z-50 bg-black/70 p-4 h-full max-h-full shadow-lg top-6 right-6 !isDragging event.key [mermaidWorkerClient] messageerror cleared worker inject via busy canParse findPrefix [markstream-react] htmlPreviewSandbox contains both allow-scripts and this only fully trusted content served an isolated en utf-8 viewport content="width=device-width initial-scale=1 html-preview-frame__backdrop--dark html-preview-frame--dark html-preview-frame__header html-preview-frame__title html-preview-frame__dot html-preview-frame__label html-preview-frame__close--dark html-preview-frame__iframe no-referrer about:blank javascript typescript go python ruby shell powershell plain cpp csharp objectivec objectivecpp yaml markdown rust kotlin java cs php sql zsh objective-c objective-cpp tag_open token.type self_closing child key ref className ms-html tag_close parse dynamic template html-inline-node html-inline-node--loading thinking htmlFor [katexWorkerClient] init cache-hit timeout waiting slot document role aria-describedby sequencediagram classdiagram kind statediagram erdiagram flowchart graph prototype constructor normalizedType process katex value?.useMonaco stream-diffs/markstream npm development hunk !options.preserveBlankKind context removed added markstream-pre__diff-pane--inline original markstream-pre__diff-pane--original modified markstream-pre__diff-pane--modified ui-monospace monospace fontFamily markstream-pre--line-numbers markstream-pre--diff-preview markstream-pre--diff-inline showLineNumbers markstream-pre__diff-code line.empty markstream-pre__diff-line--empty markstream-pre__diff-rail markstream-pre__diff-number markstream-pre__diff-content markstream-pre__diff-content-inner markstream-pre__line-numbers markstream-pre__line-numbers-text markstream-pre__code mathRef rendering math-rendering math-inline--hidden math-inline__loading math-inline__spinner globalThis.requestAnimationFrame globalThis.cancelAnimationFrame module did expected °C`;
2
2
  module.exports = safeList;
3
3
  module.exports.safeList = safeList;
4
4
  module.exports.default = safeList;
package/dist/tailwind.js CHANGED
@@ -1,2 +1,2 @@
1
- export const safeList = `use client react stream-markdown-parser string cannot delete global call clearGlobalCustomComponents checkbox-node checkbox checkbox-input blockquote-node auto emoji-node note is-dark data-index-key headerId admonition-header admonition-icon admonition-title admonition-toggle aria-expanded aria-controls collapsed admonition-content aria-labelledby clsx heading-node font-semibold object emphasis-node dl definition-list indexKey mb-4 dt definition-term ctx renderNode ?? definition dd definition-desc ml-4 dependency is not install it to enable smooth footnote-reference handleScroll footnote-link cursor-pointer html-block-node safe escape html-block html-block-node__placeholder html-block-node__placeholder-bar w-4/5 w-2/3 setHostEl shouldRender useDynamic reactNodes mark highlight-node footnote-node flex text-sm leading-relaxed border-t border-[var(--footnote-border,#eaecef)] pt-2 flex-1 footnote-anchor hover:underline ↩︎ list-item pl-1.5 my-2 valueAttr children hard-break primary fallback failed is-loaded lazy eager async image image-node__placeholder image-node__spinner image-node__placeholder-text image… placeholder image-node__error currentColor load number ease-in-out typeof infinite node.title top link-loading inline-flex items-baseline gap-1.5 link-text-wrapper relative leading-[normal] link-text text link-loading-indicator link-node aria-label noopener noreferrer list-node my-5 pl-[calc(13/8*1em)] list-decimal list-disc max-lg:my-[calc(4/3*1em)] max-lg:pl-[calc(14/9*1em)] list unknown-node text-gray-500 italic node insert-node href name xlink:href markstream-d2-root-svg window.requestAnimationFrame instance.render instance missing render returned empty d2-block my-4 rounded-lg border overflow-hidden shadow-sm border-gray-700/30 bg-gray-900 text-gray-100 border-gray-200 bg-white text-gray-900 d2-block-header justify-between items-center px-4 py-2.5 border-b border-gray-400/5 gap-x-2 font-medium font-mono gap-x-1 rounded-md p-0.5 bg-gray-700 bg-gray-100 mode-btn px-2 py-1 text-xs rounded !showSource is-active showSource d2-action-btn p-2 transition-colors hover:bg-[var(--vscode-editor-selectionBackground)] copying w-3 h-3 none round aria-pressed m9 bodyRef d2-block-body bodyStyle !hasPreview d2-source py-4 d2-code d2-error mt-2 d2-render d2-svg pb-3 inline-code inline text-[85%] px-1 py-0.5 bg-[hsl(var(--secondary))] whitespace-normal break-words max-w-full text-node-stream-delta text-node-stream-delta--a text-node-stream-delta--b markstream-core plaintext data-ssr-fallback aria-busy normalizedLanguage block data-language no html_block node.type html_inline boolean mermaid infographic d2 language d2lang scroll pre-wrap configuredShowLineNumbers disableLineNumbers whitespace-pre-wrap text-node-center paragraph-node renderNodeProp paragraph child.type classAttr node.cite value void right text-right center text-center text-left table-node-wrapper table-node--loading border-[var(--table-border,#cbd5e1)] p-[calc(4/7*1em)] rowIdx bodyRows.length table-node__loading status polite table-node__spinner sr-only isOpen strong-node emphasis strikethrough-node strikethrough highlight insert subscript-node subscript superscript-node superscript thematic-break-node cssVars image-node__img code-block-node code-block mermaid-block-node d2-block-node infographic-block-node math-block overflow-x-auto min-h-[40px] node.content $$ math-inline-wrapper math-inline reference-node bg-[hsl(var(--muted))] px-1.5 mx-0.5 hover:bg-[hsl(var(--secondary))] data-reference-id customComponents html-inline vmr-container code_block text_special heading list_item definition_list footnote footnote_reference footnote_anchor admonition hardbreak inline_code checkbox_input emoji thematic_break math_inline math_block reference vmr_container label_open label_close server-renderer markdown-renderer dark data-custom-id node-slot data-node-index data-node-type node-content react-dom w-4 h-4 flex-shrink-0 library text-red-500 p-4">Failed instanceof error.message error hidden keydown transform ease fullscreen touches text-gray-400 hover:bg-gray-700 hover:text-gray-200 text-gray-600 hover:bg-gray-200 hover:text-gray-700 source hasPreview preview pending is-rendering bg-gray-800 bg-gray-50 truncate px-2.5 bg-gray-600 text-gray-200 text-gray-700 m16 isCollapsed opacity-50 cursor-not-allowed m7 m14 text-gray-300 baseCode absolute top-2 right-2 z-10 gap-2 backdrop-blur infographic-preview min-h-[360px] transition-all duration-100 inset-0 cursor-grab isDragging containerRef w-full justify-center min-h-full markstream-react fixed z-50 bg-black/70 p-4 closeModal dialog h-full max-h-full shadow-lg top-6 right-6 !isDragging cursor-grabbing next next.type window.requestIdleCallback [data-node-index] node-spacer virtualized fade-node typewriter-node node-placeholder typewriterCursorRef typewriter-cursor [data-node-type="code_block"] [data-node-type="admonition"] [data-node-type="table"] [data-node-type="math_block"] [data-node-type="html_block"] [data-node-type="image"] performance [markstream-react][perf] [data-stream-diffs-state] theme themes themeType languages stream disableFileHeader onThemeChange renderCustomHeader renderHeaderMetadata renderHeaderPrefix wrap split line-info night moon black dracula mocha frappe macchiato palenight ocean poimandres monokai laserwave tokyo slack-dark rose-pine github-dark material-theme one-dark catppuccin-mocha catppuccin-frappe catppuccin-macchiato light latte dawn lotus transparent marker diff important max-height visible height onDidUpdateDiff onDidContentSizeChange onDidLayoutChange window.MutationObserver childList record.type attributes class vitesse-dark vitesse-light unified node.code fontSize lineHeight maxHeight paddingBottom paddingTop tabSize resolvedRuntimeOptions.overflow nextOptions.unsafeCSS [data-file] [data-diff] helpers.cleanupEditor canonicalLanguage single window.cancelAnimationFrame clientX navigator.clipboard navigator.clipboard.writeText code-block-container is-diff is-plain-text code-block-header code-header-main icon-slot code-header-copy min-w-0 code-header-title code-header-caption code-header-actions code-action-btn action-icon copied evenodd code-block-body--collapsed code-block-body--expanded code-fallback-plain m-0 code-editor-layer code-height-placeholder editorReady aria-hidden code-editor-fallback-surface code-loading-placeholder loading-skeleton skeleton-line short loose strict viewBox gantt open-modal [data-mermaid-wrapper] mermaid-action-btn toggle-mode common.zoomIn common.zoomOut common.resetZoom transition-[height] duration-150 ease-out data-mermaid-wrapper mermaid-loading mermaid-spinner diagram… mermaid-block-header space-x-2 space-x-1 common.preview common.source common.export mermaid-error hasRenderedOnce mermaid-block modeContainerRef mermaid-modal-overlay mermaid-modal-panel mermaid-modal-header mermaid-modal-title mermaid-modal-close mermaid-modal-body modalContentRef mermaid-modal-content available default abort timed out hr-node thematic-break containerClass text-node pointermove pointerup pointercancel my-8 table-node colgroup table-node__resize-handle event.key in zoom javascript typescript go python ruby shell powershell plain cpp csharp objectivec objectivecpp yaml markdown rust kotlin java cs php sql zsh objective-c objective-cpp window.matchMedia ms-tooltip z-[9999] inline-block text-base py-2 px-3 shadow-md whitespace-nowrap pointer-events-none tooltip-element text-white border-gray-700 tooltip tag_open token.type self_closing child key ref className ms-html tag_close parse dynamic template html-inline-node html-inline-node--loading [markstream-react] htmlPreviewSandbox contains both allow-scripts and this only fully trusted content served an isolated en utf-8 viewport content="width=device-width initial-scale=1 html-preview-frame__backdrop--dark html-preview-frame--dark html-preview-frame__header html-preview-frame__title html-preview-frame__dot html-preview-frame__label html-preview-frame__close--dark html-preview-frame__iframe no-referrer about:blank [mermaidWorkerClient] messageerror cleared worker inject via busy canParse findPrefix npm development process [katexWorkerClient] init cache-hit timeout waiting slot thinking htmlFor sequencediagram classdiagram kind statediagram erdiagram flowchart graph prototype constructor hunk !options.preserveBlankKind context removed added markstream-pre__diff-pane--inline original markstream-pre__diff-pane--original modified markstream-pre__diff-pane--modified ui-monospace monospace fontFamily markstream-pre--line-numbers markstream-pre--diff-preview markstream-pre--diff-inline showLineNumbers markstream-pre__diff-code line.empty markstream-pre__diff-line--empty markstream-pre__diff-rail markstream-pre__diff-number markstream-pre__diff-content markstream-pre__diff-content-inner markstream-pre__line-numbers markstream-pre__line-numbers-text markstream-pre__code normalizedType katex mathRef rendering math-rendering role aria-describedby document math-inline--hidden math-inline__loading math-inline__spinner value?.useMonaco stream-diffs/markstream globalThis.requestAnimationFrame globalThis.cancelAnimationFrame module did expected °C`;
1
+ export const safeList = `use client react stream-markdown-parser string cannot delete global call clearGlobalCustomComponents note is-dark data-index-key headerId admonition-header admonition-icon admonition-title admonition-toggle aria-expanded aria-controls collapsed admonition-content aria-labelledby checkbox-node checkbox checkbox-input emoji-node smooth footnote-anchor text-sm hover:underline cursor-pointer ↩︎ clsx auto heading-node font-semibold object html-block-node safe escape html-block html-block-node__placeholder html-block-node__placeholder-bar w-4/5 w-2/3 setHostEl shouldRender useDynamic reactNodes mark highlight-node emphasis-node footnote-node flex leading-relaxed border-t border-[var(--footnote-border,#eaecef)] pt-2 flex-1 hard-break dl definition-list indexKey mb-4 dt definition-term ctx renderNode ?? definition dd definition-desc ml-4 footnote-reference handleScroll footnote-link dependency is not install it to enable blockquote-node href name xlink:href typeof markstream-d2-root-svg number window.requestAnimationFrame instance.render instance missing render returned empty top d2-block my-4 rounded-lg border overflow-hidden shadow-sm border-gray-700/30 bg-gray-900 text-gray-100 border-gray-200 bg-white text-gray-900 d2-block-header justify-between items-center px-4 py-2.5 border-b border-gray-400/5 gap-x-2 font-medium font-mono gap-x-1 rounded-md p-0.5 bg-gray-700 bg-gray-100 mode-btn px-2 py-1 text-xs rounded !showSource is-active showSource d2-action-btn p-2 transition-colors hover:bg-[var(--vscode-editor-selectionBackground)] copying w-3 h-3 none currentColor round aria-pressed m9 bodyRef d2-block-body bodyStyle !hasPreview d2-source py-4 d2-code d2-error mt-2 d2-render d2-svg pb-3 next code_block next.type window.requestIdleCallback [data-node-index] node-spacer dark virtualized data-custom-id node-slot data-node-index data-node-type fade-node typewriter-node node-placeholder typewriterCursorRef typewriter-cursor admonition math_block html_block image [data-node-type="code_block"] [data-node-type="admonition"] [data-node-type="table"] [data-node-type="math_block"] [data-node-type="html_block"] [data-node-type="image"] performance [markstream-react][perf] mermaid markdown-renderer boolean markstream-core plaintext data-ssr-fallback aria-busy normalizedLanguage block data-language no node.type html_inline infographic d2 language d2lang scroll pre-wrap configuredShowLineNumbers disableLineNumbers whitespace-pre-wrap text-node-center text paragraph-node renderNodeProp paragraph child.type classAttr node.cite children list-item pl-1.5 my-2 value void list-node my-5 pl-[calc(13/8*1em)] list-decimal list-disc max-lg:my-[calc(4/3*1em)] max-lg:pl-[calc(14/9*1em)] list right text-right center text-center text-left table-node-wrapper table-node--loading border-[var(--table-border,#cbd5e1)] p-[calc(4/7*1em)] rowIdx bodyRows.length table-node__loading status polite table-node__spinner sr-only isOpen strong-node emphasis strikethrough-node strikethrough highlight insert-node insert subscript-node subscript superscript-node superscript thematic-break-node inline-code inline text-[85%] px-1 py-0.5 bg-[hsl(var(--secondary))] whitespace-normal break-words max-w-full ease-in-out infinite node.title link-loading inline-flex items-baseline gap-1.5 cssVars link-text-wrapper relative leading-[normal] link-text link-loading-indicator link-node aria-label noopener noreferrer image-node__img is-loaded eager lazy async code-block-node code-block mermaid-block-node d2-block-node infographic-block-node math-block overflow-x-auto min-h-[40px] node.content $$ math-inline-wrapper math-inline reference-node bg-[hsl(var(--muted))] px-1.5 mx-0.5 hover:bg-[hsl(var(--secondary))] data-reference-id customComponents html-inline vmr-container unknown-node text-gray-500 italic node text_special heading list_item definition_list footnote footnote_reference footnote_anchor hardbreak inline_code checkbox_input emoji thematic_break math_inline reference vmr_container label_open label_close server-renderer node-content pointermove pointerup pointercancel my-8 table-node colgroup table-node__resize-handle text-node text-node-stream-delta text-node-stream-delta--a text-node-stream-delta--b in out zoom failed load [data-stream-diffs-state] theme themes themeType languages stream disableFileHeader onThemeChange renderCustomHeader renderHeaderMetadata renderHeaderPrefix wrap split line-info night moon black dracula mocha frappe macchiato palenight ocean poimandres monokai laserwave tokyo slack-dark rose-pine github-dark material-theme one-dark catppuccin-mocha catppuccin-frappe catppuccin-macchiato light latte dawn lotus transparent marker diff important max-height visible hidden height onDidUpdateDiff onDidContentSizeChange onDidLayoutChange window.MutationObserver childList record.type attributes class vitesse-dark vitesse-light unified node.code fontSize lineHeight maxHeight paddingBottom paddingTop tabSize resolvedRuntimeOptions.overflow nextOptions.unsafeCSS [data-file] [data-diff] helpers.cleanupEditor canonicalLanguage single window.cancelAnimationFrame clientX navigator.clipboard navigator.clipboard.writeText code-block-container is-rendering is-diff is-plain-text code-block-header code-header-main icon-slot h-4 w-4 flex-shrink-0 code-header-copy min-w-0 code-header-title truncate code-header-caption code-header-actions code-action-btn action-icon copied m14 evenodd code-block-body--collapsed code-block-body--expanded code-fallback-plain m-0 code-editor-layer code-height-placeholder editorReady aria-hidden code-editor-fallback-surface code-loading-placeholder loading-skeleton skeleton-line short valueAttr primary fallback image-node__placeholder image-node__spinner image-node__placeholder-text image… placeholder image-node__error hr-node thematic-break containerClass react-dom window.matchMedia fixed markstream-react ms-tooltip z-[9999] inline-block text-base py-2 px-3 shadow-md whitespace-nowrap pointer-events-none tooltip-element text-white border-gray-700 tooltip loose strict viewBox gantt open-modal keydown fullscreen [data-mermaid-wrapper] mermaid-action-btn text-gray-400 hover:bg-gray-700 hover:text-gray-200 text-gray-600 hover:bg-gray-200 hover:text-gray-700 toggle-mode preview absolute top-2 right-2 z-10 gap-2 backdrop-blur common.zoomIn common.zoomOut common.resetZoom min-h-[360px] transition-[height] duration-150 ease-out bg-gray-50 data-mermaid-wrapper inset-0 cursor-grab cursor-grabbing w-full justify-center min-h-full mermaid-loading mermaid-spinner diagram… mermaid-block-header bg-gray-800 space-x-2 space-x-1 px-2.5 bg-gray-600 text-gray-200 text-gray-700 common.preview source common.source m16 opacity-50 cursor-not-allowed common.export m7 text-gray-300 mermaid-error hasRenderedOnce pending mermaid-block modeContainerRef isCollapsed mermaid-modal-overlay mermaid-modal-panel dialog mermaid-modal-header mermaid-modal-title mermaid-modal-close closeModal mermaid-modal-body modalContentRef mermaid-modal-content available default abort timed library text-red-500 p-4">Failed instanceof error.message error transform ease touches hasPreview baseCode infographic-preview transition-all duration-100 isDragging containerRef z-50 bg-black/70 p-4 h-full max-h-full shadow-lg top-6 right-6 !isDragging event.key [mermaidWorkerClient] messageerror cleared worker inject via busy canParse findPrefix [markstream-react] htmlPreviewSandbox contains both allow-scripts and this only fully trusted content served an isolated en utf-8 viewport content="width=device-width initial-scale=1 html-preview-frame__backdrop--dark html-preview-frame--dark html-preview-frame__header html-preview-frame__title html-preview-frame__dot html-preview-frame__label html-preview-frame__close--dark html-preview-frame__iframe no-referrer about:blank javascript typescript go python ruby shell powershell plain cpp csharp objectivec objectivecpp yaml markdown rust kotlin java cs php sql zsh objective-c objective-cpp tag_open token.type self_closing child key ref className ms-html tag_close parse dynamic template html-inline-node html-inline-node--loading thinking htmlFor [katexWorkerClient] init cache-hit timeout waiting slot document role aria-describedby sequencediagram classdiagram kind statediagram erdiagram flowchart graph prototype constructor normalizedType process katex value?.useMonaco stream-diffs/markstream npm development hunk !options.preserveBlankKind context removed added markstream-pre__diff-pane--inline original markstream-pre__diff-pane--original modified markstream-pre__diff-pane--modified ui-monospace monospace fontFamily markstream-pre--line-numbers markstream-pre--diff-preview markstream-pre--diff-inline showLineNumbers markstream-pre__diff-code line.empty markstream-pre__diff-line--empty markstream-pre__diff-rail markstream-pre__diff-number markstream-pre__diff-content markstream-pre__diff-content-inner markstream-pre__line-numbers markstream-pre__line-numbers-text markstream-pre__code mathRef rendering math-rendering math-inline--hidden math-inline__loading math-inline__spinner globalThis.requestAnimationFrame globalThis.cancelAnimationFrame module did expected °C`;
2
2
  export default safeList;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "markstream-react",
3
3
  "type": "module",
4
- "version": "0.1.0-beta.3",
4
+ "version": "2.0.0",
5
5
  "description": "React/Next.js streaming Markdown renderer for AI chat, LLM token streams, SSE/WebSocket output, incomplete Markdown, long documents, Mermaid, KaTeX, stream-diffs powered code blocks, and custom React components.",
6
6
  "author": "Simon He",
7
7
  "license": "MIT",
@@ -79,19 +79,6 @@
79
79
  "files": [
80
80
  "dist"
81
81
  ],
82
- "scripts": {
83
- "dev": "vite dev",
84
- "build": "pnpm --dir ../markdown-parser build && pnpm --dir ../markstream-core build && vite build --mode npm && node ../../scripts/cleanup-style-entry.mjs && node ./scripts/finalize-tailwind-export.mjs && vite build -c vite.config.tailwind.ts --mode npm && node ./scripts/copy-tailwind-css.mjs && node ../../scripts/generate-px-css.mjs && pnpm run build:dts && node ./scripts/ensure-next-client-directive.mjs",
85
- "build:analyze": "ANALYZE=true pnpm build",
86
- "build:dts": "rollup -c ./scripts/rollup.dts.config.mjs && node ./scripts/clean-dts.cjs",
87
- "check:exports": "node ../../scripts/check-react-package-exports.mjs",
88
- "preview": "vite preview",
89
- "typecheck": "tsc --noEmit && tsc -p ../../test/react-local-component-maps-types.tsconfig.json --noEmit",
90
- "size:check": "node ../../scripts/check-package-size.mjs",
91
- "check:core-published": "node ../../scripts/check-core-published.mjs --package-json package.json --core-package-json ../markstream-core/package.json",
92
- "check:workspace-deps-published": "node ../../scripts/check-workspace-deps-published.mjs --package-json package.json",
93
- "release": "pnpm run check:workspace-deps-published && bumpp --all --commit --no-tag --no-push --execute 'pnpm --workspace-root run docs:llms:generate' && DIST_TAG=\"$(node ../../scripts/dist-tag.mjs)\" && pnpm publish --access public --tag \"${DIST_TAG}\" && node ../../scripts/tag-package.mjs --package-json package.json --push"
94
- },
95
82
  "peerDependencies": {
96
83
  "@antv/infographic": "^0.2.3",
97
84
  "@terrastruct/d2": ">=0.1.33",
@@ -121,8 +108,8 @@
121
108
  "dependencies": {
122
109
  "@floating-ui/dom": "^1.8.0",
123
110
  "clsx": "^2.1.1",
124
- "markstream-core": "1.1.0-beta.2",
125
- "stream-markdown-parser": "1.2.6-beta.1"
111
+ "markstream-core": "2.0.0",
112
+ "stream-markdown-parser": "1.2.8"
126
113
  },
127
114
  "devDependencies": {
128
115
  "@types/react": "^18.3.31",
@@ -136,5 +123,18 @@
136
123
  "typescript": "^5.9.3",
137
124
  "vite": "^7.3.6",
138
125
  "vite-plugin-dts": "^4.5.4"
126
+ },
127
+ "scripts": {
128
+ "dev": "vite dev",
129
+ "build": "pnpm --dir ../markdown-parser build && pnpm --dir ../markstream-core build && vite build --mode npm && node ../../scripts/cleanup-style-entry.mjs && node ./scripts/finalize-tailwind-export.mjs && vite build -c vite.config.tailwind.ts --mode npm && node ./scripts/copy-tailwind-css.mjs && node ../../scripts/generate-px-css.mjs && pnpm run build:dts && node ./scripts/ensure-next-client-directive.mjs",
130
+ "build:analyze": "ANALYZE=true pnpm build",
131
+ "build:dts": "rollup -c ./scripts/rollup.dts.config.mjs && node ./scripts/clean-dts.cjs",
132
+ "check:exports": "node ../../scripts/check-react-package-exports.mjs",
133
+ "preview": "vite preview",
134
+ "typecheck": "tsc --noEmit && tsc -p ../../test/react-local-component-maps-types.tsconfig.json --noEmit",
135
+ "size:check": "node ../../scripts/check-package-size.mjs",
136
+ "check:core-published": "node ../../scripts/check-core-published.mjs --package-json package.json --core-package-json ../markstream-core/package.json",
137
+ "check:workspace-deps-published": "node ../../scripts/check-workspace-deps-published.mjs --package-json package.json",
138
+ "release": "pnpm run check:workspace-deps-published && bumpp --all --commit --no-tag --no-push --execute 'pnpm --workspace-root run docs:llms:generate' && DIST_TAG=\"$(node ../../scripts/dist-tag.mjs)\" && pnpm publish --access public --tag \"${DIST_TAG}\" && node ../../scripts/tag-package.mjs --package-json package.json --push"
139
139
  }
140
- }
140
+ }