Skip to content

Commit

Permalink
refactor(User card): move Share action to menu (#706)
Browse files Browse the repository at this point in the history
  • Loading branch information
raphodn authored Aug 16, 2024
1 parent ea0e2b8 commit 7e8df3c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 10 deletions.
3 changes: 3 additions & 0 deletions src/components/UserActionMenuButton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
<v-icon>mdi-dots-vertical</v-icon>
<v-menu activator="parent" scroll-strategy="close" transition="slide-y-transition">
<v-list>
<ShareLink :overrideUrl="'/users/' + user.user_id" display="list-item" />
<v-divider />
<OpenFoodFactsLink facet="editor" :value="user.user_id" display="list-item" />
</v-list>
</v-menu>
Expand All @@ -14,6 +16,7 @@ import { defineAsyncComponent } from 'vue'
export default {
components: {
ShareLink: defineAsyncComponent(() => import('../components/ShareLink.vue')),
OpenFoodFactsLink: defineAsyncComponent(() => import('../components/OpenFoodFactsLink.vue'))
},
props: {
Expand Down
11 changes: 1 addition & 10 deletions src/views/UserDetail.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,6 @@
</v-col>
</v-row>

<v-row class="mt-0">
<v-col cols="12">
<ShareLink display="button" />
</v-col>
</v-row>

<br>

<v-row>
<v-col>
<h2 class="text-h6 d-inline mr-2">
Expand Down Expand Up @@ -51,8 +43,7 @@ export default {
UserCard: defineAsyncComponent(() => import('../components/UserCard.vue')),
FilterMenu: defineAsyncComponent(() => import('../components/FilterMenu.vue')),
OrderMenu: defineAsyncComponent(() => import('../components/OrderMenu.vue')),
PriceCard: defineAsyncComponent(() => import('../components/PriceCard.vue')),
ShareLink: defineAsyncComponent(() => import('../components/ShareLink.vue'))
PriceCard: defineAsyncComponent(() => import('../components/PriceCard.vue'))
},
data() {
return {
Expand Down

0 comments on commit 7e8df3c

Please sign in to comment.