refactor(CodeViewer): change children prop type to React.ReactNode

- Updated the children prop type in CodeViewer from string to React.ReactNode for improved flexibility in rendering various content types.
This commit is contained in:
MyPrototypeWhat 2025-09-03 17:20:01 +08:00
parent 7f87fb9c26
commit 4b7b0a3823

View File

@ -12,7 +12,7 @@ import styled from 'styled-components'
interface CodeViewerProps {
language: string
children: string
children: React.ReactNode
expanded?: boolean
wrapped?: boolean
onHeightChange?: (scrollHeight: number) => void