This commit is contained in:
IndieKKY
2024-10-06 19:16:22 +08:00
parent 9bcf6ee48d
commit 2460b0b822
12 changed files with 32 additions and 25 deletions

View File

@@ -20,6 +20,7 @@ import {EVENT_EXPAND, GEMINI_TOKENS, TOTAL_HEIGHT_MAX, TOTAL_HEIGHT_MIN, WORDS_M
import {useAsyncEffect, useInterval} from 'ahooks'
import {getModelMaxTokens, getWholeText} from '../utils/bizUtil'
import useMessaging from '../messaging/layer2/useMessaging'
import { useMessage } from './message'
/**
* Service是单例类似后端的服务概念
@@ -43,7 +44,7 @@ const useSubtitleService = () => {
const autoTranslate = useAppSelector(state => state.env.autoTranslate)
const reviewed = useAppSelector(state => state.env.tempData.reviewed)
const reviewActions = useAppSelector(state => state.env.tempData.reviewActions)
const {sendInject} = useMessaging()
const {sendInject} = useMessage()
//如果reviewActions达到15次则设置reviewed为false
useEffect(() => {