diff --git a/aiChat/components/bottomSend.vue b/aiChat/components/bottomSend.vue index 71537f0..280312a 100644 --- a/aiChat/components/bottomSend.vue +++ b/aiChat/components/bottomSend.vue @@ -141,10 +141,16 @@ export default { }, methods: { promptInputFocusHandle() { - this.inputOnFocus = true + setTimeout(() => { + this.inputOnFocus = true + this.$emit('focus', 1) + }, 200) }, promptInputBlurHandle() { - this.inputOnFocus = false + setTimeout(() => { + this.inputOnFocus = false + this.$emit('focus', 0) + }, 200) }, toggleInputModel() { if (!this.token) { diff --git a/aiChat/mixins/chatMixins.js b/aiChat/mixins/chatMixins.js index da26fcc..4183d2c 100644 --- a/aiChat/mixins/chatMixins.js +++ b/aiChat/mixins/chatMixins.js @@ -21,6 +21,7 @@ export const chatMixins = { statusBarHeight: 20, fileHttpStr: Object.freeze(VUE_APP_API_URL + settings.sysPrefix), optionsFrom: '', + onFocus: false, loading: false, chatNumber: '', infoResData: {}, @@ -86,6 +87,9 @@ export const chatMixins = { createdCallbak() { console.log('页面初始话回调') }, + inputFocusHandle(value) { + this.onFocus = value === 1 + }, historyViewHandle() { console.log(this.$refs.historyView) this.$refs.historyView.showView() diff --git a/aiChat/views/history.vue b/aiChat/views/history.vue index 75d68a2..93f38e9 100644 --- a/aiChat/views/history.vue +++ b/aiChat/views/history.vue @@ -130,7 +130,12 @@ - + - +