mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-24 05:48:59 +08:00
@@ -30,11 +30,11 @@ export const HighlightText = ({ text = '', end, start }: HighlightProps) => {
|
||||
|
||||
return (
|
||||
<span className={styles.highlightText}>
|
||||
{parts.map(part =>
|
||||
{parts.map((part, index) =>
|
||||
typeof part === 'string' ? (
|
||||
<Fragment key={part}>{part}</Fragment>
|
||||
) : (
|
||||
<span key={part.h} className={styles.highlightKeyword}>
|
||||
<span key={part.h + '.' + index} className={styles.highlightKeyword}>
|
||||
{part.h}
|
||||
</span>
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user