11 KiB
@assistant-ui/react-streamdown
0.3.5
Patch Changes
0.3.4
Patch Changes
-
#4408
b6016d1- feat: export math-delimiter preprocess helpers for the markdown text primitives (@okisdev)adds
normalizeMathDelimiters,rewriteLatexBracketDelimiters,rewriteCustomMathTags, andescapeCurrencyDollarsso you can pass them to thepreprocessprop instead of copy-pasting a regex blob. they rewrite the\(...\)/\[...\]brackets and[/math]/[/inline]tags that models emit to the$...$/$$...$$form remark-math parses, and escape$5-style currency so single-dollar math doesn't eat it. -
#4418
2a03d96- perf: repair only the trailing block of streaming markdown instead of the whole message (@okisdev)StreamdownTextPrimitivelet Streamdown runremend(incomplete-markdown repair) over the entire accumulated message on every streaming flush, which grows with the message. It now repairs only the last top-level block (the only place a dangling opener can be, since inline constructs cannot cross a blank line and blocks are split after repair), which is render-equivalent but bounds the heavierremendrepair to the tail instead of running it over the whole message each flush.tailBoundedRemendandfindRemendWindowStartare exported so you can apply the same windowing yourself. Customremendoptions are honored, repair falls back to the full message when a customparseMarkdownIntoBlocksFnis supplied, andparseIncompleteMarkdown={false}still disables repair entirely.
0.3.3
Patch Changes
-
#4348
5ca6558- feat: opt-indeferprop on the markdown text primitives (@okisdev)StreamdownTextPrimitiveandMarkdownTextPrimitiveaccept adeferflag that routes the streamed text throughuseDeferredValue, so re-parsing the growing message runs at a lower priority and typing/scrolling stay responsive while a long message streams in. intermediate streaming states may be skipped under load; the final text always renders. default off; the shadcn kit's markdown-text turns it on. -
#4357
fb1a7d3- feat:smoothprop onStreamdownTextPrimitive(@okisdev)opt-in typewriter reveal via the now-public
useSmooth, acceptingboolean | SmoothOptions. the pipeline runs preprocess, then smooth, then the existingdeferdeferral, anddata-status/isAnimatingderive from the smooth status so the caret keeps blinking and the copy/download controls stay disabled until the reveal catches up. default off; streamdown's block memoization bounds the per-frame cost to linear string scans plus the tail block parse. the@assistant-ui/reactpeer floor moves to the release that shipsSmoothOptions.
0.3.2
Patch Changes
0.3.1
Patch Changes
0.3.0
Patch Changes
- Updated dependencies [
040d469]:
0.2.0
Patch Changes
0.1.11
Patch Changes
-
#3851
e19c347- fix: pass memoized code component to streamdown instead of invoking it as a function, and render CodeHeader when no SyntaxHighlighter is configured for a block (@okisdev) -
Updated dependencies [
ce865bc,c56f98f,9aa5410,a1f84ae,b4fde97,d53ff4f,17958c9,477fa8a]:
0.1.10
Patch Changes
- c988db8: chore: update dependencies
- Updated dependencies [c988db8]
0.1.9
Patch Changes
- bdce66f: chore: update dependencies
- 209ae81: chore: remove aui-source export condition from package.json exports
- Updated dependencies [6554892]
- Updated dependencies [d726499]
- Updated dependencies [876f75d]
- Updated dependencies [bdce66f]
- Updated dependencies [c362685]
- Updated dependencies [4abb898]
- Updated dependencies [209ae81]
- Updated dependencies [50b3100]
- Updated dependencies [af70d7f]
0.1.8
Patch Changes
- 52403c3: chore: update dependencies
- Updated dependencies [3227e71]
- Updated dependencies [52403c3]
0.1.7
Patch Changes
- 736344c: chore: update dependencies
- 3bd38ed: fix(react-streamdown): preserve data-block in PreOverride for block code detection
- Updated dependencies [28a987a]
- Updated dependencies [736344c]
- Updated dependencies [ff3be2a]
- Updated dependencies [70b19f3]
- Updated dependencies [70b19f3]
- Updated dependencies [c71cb58]
0.1.6
Patch Changes
- 349f3c7: chore: update deps
- Updated dependencies [1ed9867]
- Updated dependencies [427ffaa]
- Updated dependencies [349f3c7]
- Updated dependencies [02614aa]
- Updated dependencies [642bcda]
0.1.5
Patch Changes
- 613c884: fix(react-streamdown): useMessagePartText provide status
- Updated dependencies [5ae74fe]
- Updated dependencies [8ed9d6f]
0.1.4
Patch Changes
- 36ef3a2: chore: update dependencies
- Updated dependencies [36ef3a2]
- Updated dependencies [6692226]
- Updated dependencies [c31c0fa]
- Updated dependencies [1672be8]
- Updated dependencies [28f39fe]
- Updated dependencies [3a1cb66]
- Updated dependencies [14769af]
- Updated dependencies [7c360ce]
- Updated dependencies [a638f05]
- Updated dependencies [8a78cd2]
0.1.3
Patch Changes
- 93910bd: Rename .tsx files to .ts where no JSX syntax is used
- Updated dependencies [5bbe8a9]
- Updated dependencies [5e304ea]
- Updated dependencies [546c053]
- Updated dependencies [a7039e3]
- Updated dependencies [16c10fd]
- Updated dependencies [98c3d54]
- Updated dependencies [b181803]
- Updated dependencies [7836760]
- Updated dependencies [9276547]
- Updated dependencies [b65428e]
- Updated dependencies [af5b085]
- Updated dependencies [61b54e9]
- Updated dependencies [a094c45]
- Updated dependencies [4d7f712]
- Updated dependencies [ecc29ec]
- Updated dependencies [6e97999]
- Updated dependencies [a247fc9]
- Updated dependencies [f414af9]
- Updated dependencies [b48912c]
- Updated dependencies [93910bd]
- Updated dependencies [58a8472]
0.1.2
Patch Changes
- a088518: chore: update dependencies
- Updated dependencies [a088518]
- Updated dependencies [d8122cc]
0.1.1
Patch Changes
- d45b893: chore: update dependencies
- Updated dependencies [d45b893]
- Updated dependencies [fe71bfc]
0.1.0
Minor Changes
-
378a9fd: feat: add @assistant-ui/react-streamdown package
New package providing Streamdown-based markdown rendering as an alternative to
@assistant-ui/react-markdown.Features:
StreamdownTextPrimitivecomponent for rendering markdown- Built-in support for Shiki syntax highlighting, KaTeX math, and Mermaid diagrams via plugins
- Compatibility API for migrating from react-markdown (SyntaxHighlighter, CodeHeader, componentsByLanguage)
- Optimized streaming with block-based rendering and remend
Patch Changes
- Updated dependencies [07d1c65]
- Updated dependencies [b591d72]
- Updated dependencies [59a338a]
- Updated dependencies [acbaf07]
- Updated dependencies [c665612]
- Updated dependencies [0371d72]
- Updated dependencies [e8b3f34]