fix: Unfiltered special characters in voice playback (#2777)
This commit is contained in:
parent
27bc01d442
commit
74d10b61bc
@ -99,7 +99,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { nextTick, onMounted, ref } from 'vue'
|
import { nextTick, onMounted, ref, onBeforeUnmount } from 'vue'
|
||||||
import { useRoute } from 'vue-router'
|
import { useRoute } from 'vue-router'
|
||||||
import { copyClick } from '@/utils/clipboard'
|
import { copyClick } from '@/utils/clipboard'
|
||||||
import applicationApi from '@/api/application'
|
import applicationApi from '@/api/application'
|
||||||
@ -489,7 +489,7 @@ class AudioManage {
|
|||||||
// text 处理成纯文本
|
// text 处理成纯文本
|
||||||
text = markdownToPlainText(text)
|
text = markdownToPlainText(text)
|
||||||
const split = smartSplit(
|
const split = smartSplit(
|
||||||
props.data.answer_text,
|
text,
|
||||||
{
|
{
|
||||||
0: 20,
|
0: 20,
|
||||||
1: 50,
|
1: 50,
|
||||||
@ -526,6 +526,11 @@ onMounted(() => {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
onBeforeUnmount(() => {
|
||||||
|
if (audioManage.value) {
|
||||||
|
audioManage.value.pause()
|
||||||
|
}
|
||||||
|
})
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
@media only screen and (max-width: 430px) {
|
@media only screen and (max-width: 430px) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user