diff --git a/pkg/views/.eslintrc.js b/pkg/views/.eslintrc.js new file mode 100644 index 0000000..b2d47e8 --- /dev/null +++ b/pkg/views/.eslintrc.js @@ -0,0 +1,6 @@ +module.exports = { + extends: ["plugin:vue/vue3-recommended"], + rules: { + "vue/multi-word-component-names": "off", + }, +} diff --git a/pkg/views/src/layouts/master.vue b/pkg/views/src/layouts/master.vue index 7553a77..e8b7d05 100644 --- a/pkg/views/src/layouts/master.vue +++ b/pkg/views/src/layouts/master.vue @@ -19,7 +19,7 @@ - + diff --git a/pkg/views/src/layouts/user-center.vue b/pkg/views/src/layouts/user-center.vue new file mode 100644 index 0000000..1919bc0 --- /dev/null +++ b/pkg/views/src/layouts/user-center.vue @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/pkg/views/src/router/index.ts b/pkg/views/src/router/index.ts index aff742b..7871bd6 100644 --- a/pkg/views/src/router/index.ts +++ b/pkg/views/src/router/index.ts @@ -1,6 +1,7 @@ import { createRouter, createWebHistory } from "vue-router" import { useUserinfo } from "@/stores/userinfo" import MasterLayout from "@/layouts/master.vue" +import UserCenterLayout from "@/layouts/user-center.vue" const router = createRouter({ history: createWebHistory(import.meta.env.BASE_URL), @@ -8,7 +9,16 @@ const router = createRouter({ { path: "/", component: MasterLayout, - children: [{ path: "/", name: "dashboard", component: () => import("@/views/dashboard.vue") }], + children: [ + { + path: "/", + component: UserCenterLayout, + children: [ + { path: "/", name: "dashboard", component: () => import("@/views/dashboard.vue") }, + { path: "/me/personalize", name: "personalize", component: () => import("@/views/personalize.vue") }, + ], + }, + ], }, { path: "/auth", diff --git a/pkg/views/src/views/dashboard.vue b/pkg/views/src/views/dashboard.vue index 608217b..b52e447 100644 --- a/pkg/views/src/views/dashboard.vue +++ b/pkg/views/src/views/dashboard.vue @@ -1,3 +1,31 @@ - Hello, world! + + + + + + {{ id.userinfo.displayName }} + What can I help you today? + + + + + + + + diff --git a/pkg/views/src/views/personalize.vue b/pkg/views/src/views/personalize.vue new file mode 100644 index 0000000..f46d427 --- /dev/null +++ b/pkg/views/src/views/personalize.vue @@ -0,0 +1,185 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + Apply Changes + + + + + + + + + + + + + + + Your personal information has been updated. + + + Something went wrong... {{ error }} + + + + + +
What can I help you today?