diff --git a/.env b/.env
index fb74ae2..f88c72b 100644
--- a/.env
+++ b/.env
@@ -1,16 +1,16 @@
# ===========================================
# API配置 - 根据你的后端接口修改
# ===========================================
-# 开发环境
-VUE_APP_API_BASE_URL=https://localhost:8000
-VUE_APP_API_TIMEOUT=10000
+# 开发环境(Vite 只能识别 VITE_ 前缀)
+VITE_APP_API_BASE_URL=http://localhost:8000
+VITE_APP_API_TIMEOUT=10000
# ===========================================
# 应用配置
# ===========================================
-VUE_APP_APP_NAME=babyhealth
-VUE_APP_APP_VERSION=1.0.0
-VUE_APP_DEBUG=true
+VITE_APP_APP_NAME=babyhealth
+VITE_APP_APP_VERSION=1.0.0
+VITE_APP_DEBUG=true
# ===========================================
# 其他配置 (可选)
diff --git a/env.d.ts b/env.d.ts
new file mode 100644
index 0000000..b4c46e7
--- /dev/null
+++ b/env.d.ts
@@ -0,0 +1,10 @@
+///
+
+declare module '*.vue' {
+ import type { DefineComponent } from 'vue'
+ const component: DefineComponent<{}, {}, any>
+ export default component
+}
+
+// uni-app 的全局对象(让 TS 不再提示 uni 未定义)
+declare const uni: any
diff --git a/main.js b/main.js
index def4853..19fff3f 100644
--- a/main.js
+++ b/main.js
@@ -1,29 +1,12 @@
import { createSSRApp } from 'vue'
-// 引入 createPinia 方法(命名导出)
import { createPinia } from 'pinia'
import App from './App.vue'
import piniaPluginPersistedstate from 'pinia-plugin-persistedstate'
-// 引入 lime-echart 组件
-import LEchart from './uni_modules/lime-echart/components/l-echart/l-echart.vue'
-// FontAwesome CSS 将通过 App.vue 中的全局样式引入
export function createApp() {
const app = createSSRApp(App)
- // 创建 Pinia 实例
const pinia = createPinia()
- // 注册 Pinia 持久化
- pinia.use(piniaPluginPersistedstate)
- // 注册 Pinia
+ pinia.use(piniaPluginPersistedstate)
app.use(pinia)
-
- // 暂时注释掉 uView,因为与 Vue 3 有兼容性问题
- // 后续可以使用 uView Plus 或其他 Vue 3 兼容的 UI 库
- // app.use(uView)
-
- // 全局注册 lime-echart 组件
- app.component('l-echart', LEchart)
-
- return {
- app
- }
+ return { app }
}
\ No newline at end of file
diff --git a/pages/login/index.vue b/pages/login/index.vue
index fd731c0..eaace94 100644
--- a/pages/login/index.vue
+++ b/pages/login/index.vue
@@ -11,7 +11,7 @@
-
+
@@ -27,73 +27,90 @@
欢迎回来,开始您的工作之旅
-
+
-
+
-
+
-
+ @focus="handleAccountFocus"
+ @blur="handleAccountBlur"
+ @input="clearAccountError"
+ />
- {{ usernameError }}
+ {{
+ accountError
+ }}
-
+
-
+
-
+ @input="clearPasswordError"
+ />
-
+
- {{ passwordError }}
+ {{
+ passwordError
+ }}
-
+
-
+
记住我
- 忘记密码?
+ 忘记密码?
-
+
-
+
@@ -119,228 +138,161 @@
-