2424 :to =" {
2525 name: 'group',
2626 params: { selectedGroup: GROUP_ALL_CONTACTS },
27- }" >
27+ }"
28+ :active =" routeState === 'all'"
29+ @click =" updateRouteState('all')" >
2830 <template #icon >
29- <IconContact :size =" 20" />
31+ <IconContactFilled v-if =" routeState === 'all'" :size =" 20" />
32+ <IconContact v-else :size =" 20" />
3033 </template >
3134 <template #counter >
3235 <NcCounterBubble
4447 name: 'chart',
4548 params: { selectedChart: GROUP_ALL_CONTACTS },
4649 }"
47- icon =" icon-category-monitoring" />
50+ :active =" routeState === 'orgchart'"
51+ icon =" icon-category-monitoring"
52+ @click =" updateRouteState('orgchart')" />
4853
4954 <!-- Not grouped group -->
5055 <AppNavigationItem
5459 :to =" {
5560 name: 'group',
5661 params: { selectedGroup: GROUP_NO_GROUP_CONTACTS },
57- }" >
62+ }"
63+ :active =" routeState === 'notgrouped'"
64+ @click =" updateRouteState('notgrouped')" >
5865 <template #icon >
59- <IconUser :size =" 20" />
66+ <IconUserFilled v-if =" routeState === 'notgrouped'" :size =" 20" />
67+ <IconUser v-else :size =" 20" />
6068 </template >
6169 <template #counter >
6270 <NcCounterBubble
7381 :to =" {
7482 name: 'group',
7583 params: { selectedGroup: GROUP_RECENTLY_CONTACTED },
76- }" >
84+ }"
85+ :active =" routeState === 'recentlycontacted'"
86+ @click =" updateRouteState('recentlycontacted')" >
7787 <template #icon >
7888 <IconRecentlyContacted :size =" 20" />
7989 </template >
113123 <GroupNavigationItem
114124 v-for =" group in ellipsisGroupsMenu"
115125 :key =" group.key"
116- :group =" group" />
126+ :route-state =" routeState"
127+ :group =" group"
128+ @update-route-state =" updateRouteState" />
117129
118130 <template v-if =" isCirclesEnabled " >
119131 <!-- Toggle groups ellipsis -->
148160 <CircleNavigationItem
149161 v-for =" circle in ellipsisCirclesMenu"
150162 :key =" circle.key"
151- :circle =" circle" />
163+ :circle =" circle"
164+ @click =" updateRouteState(`circle:${circle.id}`)" />
152165
153166 <!-- Toggle circles ellipsis -->
154167 <AppNavigationItem
@@ -198,6 +211,8 @@ import {
198211} from ' @nextcloud/vue'
199212import { mapStores } from ' pinia'
200213import naturalCompare from ' string-natural-compare'
214+ import IconUserFilled from ' vue-material-design-icons/Account.vue'
215+ import IconContactFilled from ' vue-material-design-icons/AccountMultiple.vue'
201216import IconContact from ' vue-material-design-icons/AccountMultipleOutline.vue'
202217import IconUser from ' vue-material-design-icons/AccountOutline.vue'
203218import IconError from ' vue-material-design-icons/AlertCircleOutline.vue'
@@ -230,7 +245,9 @@ export default {
230245 ContactsSettings,
231246 GroupNavigationItem,
232247 IconContact,
248+ IconContactFilled,
233249 IconUser,
250+ IconUserFilled,
234251 IconAdd,
235252 IconError,
236253 IconLoading,
@@ -243,12 +260,7 @@ export default {
243260 props: {
244261 loading: {
245262 type: Boolean ,
246- default: true ,
247- },
248-
249- contactsList: {
250- type: Array ,
251- required: true ,
263+ default: false ,
252264 },
253265 },
254266
@@ -278,6 +290,8 @@ export default {
278290 collapsedCircles: true ,
279291
280292 showSettings: false ,
293+
294+ routeState: ' all' ,
281295 }
282296 },
283297
@@ -493,6 +507,10 @@ export default {
493507 showContactsSettings () {
494508 this .showSettings = true
495509 },
510+
511+ updateRouteState (state ) {
512+ this .routeState = state
513+ },
496514 },
497515}
498516< / script>
0 commit comments