diff options
Diffstat (limited to 'app/assets/javascripts/nav/components/top_nav_container_view.vue')
-rw-r--r-- | app/assets/javascripts/nav/components/top_nav_container_view.vue | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/app/assets/javascripts/nav/components/top_nav_container_view.vue b/app/assets/javascripts/nav/components/top_nav_container_view.vue index 6f98f85ff90..36e4a278da9 100644 --- a/app/assets/javascripts/nav/components/top_nav_container_view.vue +++ b/app/assets/javascripts/nav/components/top_nav_container_view.vue @@ -20,6 +20,10 @@ export default { type: String, required: true, }, + currentItem: { + type: Object, + required: true, + }, containerClass: { type: String, required: false, @@ -43,6 +47,12 @@ export default { { id: 'secondary', menuItems: this.linksSecondary }, ].filter((x) => x.menuItems?.length); }, + currentItemTimestamped() { + return { + ...this.currentItem, + lastAccessedOn: Date.now(), + }; + }, }, mounted() { // For historic reasons, the frequent-items-app component requires this too start up. @@ -62,7 +72,7 @@ export default { > <div class="frequent-items-dropdown-content gl-w-full! gl-pt-0!"> <vuex-module-provider :vuex-module="frequentItemsVuexModule"> - <frequent-items-app v-bind="$attrs" /> + <frequent-items-app :current-item="currentItemTimestamped" v-bind="$attrs" /> </vuex-module-provider> </div> </div> |