diff --git a/src/components/ProfileManager.vue b/src/components/ProfileManager.vue
index 09242f2..3c7eb04 100644
--- a/src/components/ProfileManager.vue
+++ b/src/components/ProfileManager.vue
@@ -14,7 +14,20 @@
-
+
+
+
+ {{ profileTag }}
+
+ {{ profile.name }} {{ profile.id }}
+
+
+
+
+
+ {{ profile.name }} {{ profile.id }}
+
+
@@ -30,6 +43,8 @@ import { MagnifyingGlassIcon } from '@radix-icons/vue'
const profiles = ref([])
+const filter = ref('')
+
const profilesByTag = computed(() => {
const map = new Map()
profiles.value.forEach(profile => {
@@ -42,6 +57,16 @@ const profilesByTag = computed(() => {
return map
})
+const filteredProfiles = computed(() => {
+ const filterLower = filter.value.toLowerCase()
+ return profiles.value.filter(profile => {
+ const nameLower = profile.name.toLowerCase()
+ const idLower = profile.id.toLowerCase()
+ const tagLower = profile.profileTag.toLowerCase()
+ return nameLower.includes(filterLower) || idLower.includes(filterLower) || tagLower.includes(filterLower)
+ })
+})
+
function fetchProfiles() {
axios.get('http://localhost:3001/profiles').then(res => {
profiles.value = res.data