diff --git a/app/app.config.ts b/app/app.config.ts index 7daabe2..b3880f3 100644 --- a/app/app.config.ts +++ b/app/app.config.ts @@ -7,6 +7,11 @@ export default defineAppConfig({ nuxtSite: "https://nuxt.com", nuxtUiSite: "https://ui3.nuxt.dev" }, + icons: { + system: "lucide:square-terminal", + storage: "lucide:archive", + interface: "lucide:app-window-mac" + }, ui: { colors: { primary: "green", @@ -37,11 +42,11 @@ export default defineAppConfig({ slots: { trigger: "cursor-pointer", item: "md:py-2" - }, + } }, navigationMenu: { slots: { - link: "cursor-pointer", + link: "cursor-pointer" }, variants: { disabled: { diff --git a/app/composables/pages.ts b/app/composables/pages.ts index 62a853a..f92862b 100644 --- a/app/composables/pages.ts +++ b/app/composables/pages.ts @@ -1,5 +1,6 @@ export const usePages = () => { const router = useRouter(); + const { icons } = useAppConfig(); const routes = router.getRoutes().filter((route) => route.name !== "index" && route.name !== "all"); @@ -10,7 +11,7 @@ export const usePages = () => { if (!acc[category]) { acc[category] = { label: category.charAt(0).toUpperCase() + category.slice(1), - icon: route.meta.categoryIcon || "i-lucide-folder", + icon: icons[category as keyof typeof icons] || "i-lucide-folder", to: route.path, children: [] }; @@ -19,7 +20,7 @@ export const usePages = () => { acc[category].children.push({ label: route.meta.name as string, description: route.meta.description as string, - icon: `i-${route.meta.icon}`, + icon: route.meta.icon, to: route.path }); diff --git a/app/pages/commands.vue b/app/pages/commands.vue index 4d16482..ffb5bc2 100644 --- a/app/pages/commands.vue +++ b/app/pages/commands.vue @@ -28,8 +28,7 @@ name: "Shell commands", icon: "lucide:terminal", description: "Execute shell commands", - category: "system", - categoryIcon: "lucide:square-terminal" + category: "system" }); const schema = z.object({ diff --git a/app/pages/file.vue b/app/pages/file.vue index e20890d..de1ad52 100644 --- a/app/pages/file.vue +++ b/app/pages/file.vue @@ -24,7 +24,6 @@ name: "Files", icon: "lucide:file-text", category: "storage", - categoryIcon: "lucide:database", description: "Create and manage files" }); diff --git a/app/pages/notifications.vue b/app/pages/notifications.vue index b298d37..37cb344 100644 --- a/app/pages/notifications.vue +++ b/app/pages/notifications.vue @@ -24,7 +24,6 @@ name: "Notifications", icon: "lucide:message-square-more", category: "interface", - categoryIcon: "lucide:app-window-mac", description: "Send native notifications" }); diff --git a/app/pages/os.vue b/app/pages/os.vue index 20d1e8c..c00117b 100644 --- a/app/pages/os.vue +++ b/app/pages/os.vue @@ -12,7 +12,6 @@ name: "OS Informations", icon: "lucide:info", category: "system", - categoryIcon: "lucide:square-terminal", description: "Read operating system informations." }); diff --git a/app/pages/store.vue b/app/pages/store.vue index 51baecd..ce96afb 100644 --- a/app/pages/store.vue +++ b/app/pages/store.vue @@ -28,7 +28,6 @@ name: "Store", icon: "lucide:database", category: "storage", - categoryIcon: "lucide:database", description: "Handle file creation in the file system" }); diff --git a/app/pages/webview.vue b/app/pages/webview.vue index 0679815..141d58b 100644 --- a/app/pages/webview.vue +++ b/app/pages/webview.vue @@ -17,9 +17,8 @@