mirror of
https://github.com/wassname/chatGPTBox.git
synced 2026-08-19 12:00:17 +08:00
feat: added a ReadButton to convert the text output from GPT into voice and read it out loud
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { useState } from 'react'
|
||||
import { ChevronDownIcon, XCircleIcon, SyncIcon } from '@primer/octicons-react'
|
||||
import CopyButton from '../CopyButton'
|
||||
import ReadButton from '../ReadButton'
|
||||
import PropTypes from 'prop-types'
|
||||
import MarkdownRender from '../MarkdownRender/markdown.jsx'
|
||||
import { useTranslation } from 'react-i18next'
|
||||
@@ -73,6 +74,9 @@ export function ConversationItem({ type, content, session, done, port, onRetry }
|
||||
{session && (
|
||||
<CopyButton contentFn={() => content.replace(/\n<hr\/>$/, '')} size={14} />
|
||||
)}
|
||||
{session && (
|
||||
<ReadButton contentFn={() => content.replace(/\n<hr\/>$/, '')} size={14} />
|
||||
)}
|
||||
{!collapsed ? (
|
||||
<span
|
||||
title={t('Collapse')}
|
||||
|
||||
Reference in New Issue
Block a user