fix: corrigé couleur texte markdown timeline
- Ajout useTheme pour accès aux couleurs Material-UI - Utilisation theme.palette.text.secondary pour le markdown - Compatible thèmes sombre et clair - Texte markdown maintenant lisible sur tous fonds
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import {useRef, useState} from 'react'
|
||||
import {useTheme} from '@mui/material/styles'
|
||||
import PropTypes from 'prop-types'
|
||||
import Box from '@mui/material/Box'
|
||||
import Typography from '@mui/material/Typography'
|
||||
@@ -113,6 +114,7 @@ function VersionCard({
|
||||
setVersionCompare,
|
||||
onVoteResult
|
||||
}) {
|
||||
const theme = useTheme()
|
||||
const status = getVersionStatus(version, index, totalVersions)
|
||||
|
||||
const statusConfig = getStatusConfig(status)
|
||||
@@ -223,9 +225,10 @@ function VersionCard({
|
||||
</Box>
|
||||
</Box>
|
||||
|
||||
<Box sx={{mb: 2, '& > div': {fontSize: '0.875rem', fontStyle: 'italic', color: 'text.secondary'}}}>
|
||||
<Box sx={{mb: 2, '& > div': {fontSize: '0.875rem', fontStyle: 'italic'}}}>
|
||||
<MarkdownRenderer
|
||||
content={contentPreview}
|
||||
color={theme.palette.text.secondary}
|
||||
fallbackComponent={({children, ...props}) => (
|
||||
<Typography
|
||||
variant='body2'
|
||||
|
||||
Reference in New Issue
Block a user