diff --git a/logo/Thumbs.db b/logo/Thumbs.db deleted file mode 100644 index 4aac3f54..00000000 Binary files a/logo/Thumbs.db and /dev/null differ diff --git a/logo/logo.png b/logo/logo.png deleted file mode 100644 index 44438b0f..00000000 Binary files a/logo/logo.png and /dev/null differ diff --git a/package.json b/package.json index 46c404fa..217b2a1a 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "vue-i18n": "^9.1.9" }, "devDependencies": { - "@dcloudio/types": "^3.4.8", + "@dcloudio/types": "^3.4.29", "@dcloudio/uni-automator": "3.0.0-4060620250520001", "@dcloudio/uni-cli-shared": "3.0.0-4060620250520001", "@dcloudio/uni-stacktracey": "3.0.0-4060620250520001", diff --git a/src/components/touch-btn/touch-btn.images.ts b/src/components/touch-btn/touch-btn.images.ts new file mode 100644 index 00000000..500a7104 --- /dev/null +++ b/src/components/touch-btn/touch-btn.images.ts @@ -0,0 +1,6 @@ +// components/touch-btn/touch-btn.images.ts +// 统一导出所有需要的图片资源 +export { default as cancelBtn } from '@/static/images/course/cancel.png'; +export { default as cancelActiveBtn } from '@/static/images/course/cancel-active.png'; +export { default as translateBtn } from '@/static/images/course/translate.png'; +export { default as translateActiveBtn } from '@/static/images/course/translate-active.png'; \ No newline at end of file diff --git a/src/components/touch-btn/touch-btn.ts b/src/components/touch-btn/touch-btn.ts new file mode 100644 index 00000000..b5802764 --- /dev/null +++ b/src/components/touch-btn/touch-btn.ts @@ -0,0 +1,15 @@ +import { get_base_url } from '@/api/request.js'; +// const url = '/trapractice/voiceCallSocket/voiceCall' +// const url = '/traapp/voiceTransSocket/open'; +const url = '/traapp/voiceAiModelSocket/open'; +const _baseUrl = get_base_url(url).split('http').join('ws'); +export const wsUrl = _baseUrl + url; +const windowInfo = uni.getWindowInfo(); +// 安全区域信息 +const safeArea = windowInfo.safeArea; +// 按钮高度 +const btnHeight = (windowInfo.screenWidth / 750) * 234; +// 按钮的顶部边界 +export const bottomAreaTopBoundary = safeArea.bottom - btnHeight; +// 屏幕横向分割线 +export const horizontalSplitX = safeArea.right / 2; \ No newline at end of file diff --git a/src/components/touch-btn/touch-btn.types.ts b/src/components/touch-btn/touch-btn.types.ts new file mode 100644 index 00000000..e88d046c --- /dev/null +++ b/src/components/touch-btn/touch-btn.types.ts @@ -0,0 +1 @@ +export type StatusType = 'voice' | 'input' | 'text'; \ No newline at end of file diff --git a/src/components/touch-btn/touch-btn.vue b/src/components/touch-btn/touch-btn.vue index 3b579e10..9581d1b8 100644 --- a/src/components/touch-btn/touch-btn.vue +++ b/src/components/touch-btn/touch-btn.vue @@ -89,27 +89,22 @@ -