Extract FollowsFilterMenuItems

- remove now unnecessary FilterPostsMenuItems
This commit is contained in:
mattwr18 2019-09-06 13:37:22 +02:00
parent 8a3bd6b770
commit e81942c6f5
3 changed files with 10 additions and 12 deletions

View File

@ -11,7 +11,10 @@
<ds-icon size="xx-small" name="angle-down" /> <ds-icon size="xx-small" name="angle-down" />
</ds-button> </ds-button>
<template slot="popover"> <template slot="popover">
<filter-posts-menu-items :chunk="chunk" :user="currentUser" /> <ds-container>
<categories-filter-menu-items :chunk="chunk" />
<follows-filter-menu-items :user="currentUser" />
</ds-container>
</template> </template>
</dropdown> </dropdown>
</template> </template>
@ -19,12 +22,14 @@
import _ from 'lodash' import _ from 'lodash'
import Dropdown from '~/components/Dropdown' import Dropdown from '~/components/Dropdown'
import { mapGetters } from 'vuex' import { mapGetters } from 'vuex'
import FilterPostsMenuItems from '~/components/FilterPosts/FilterPostsMenuItems' import CategoriesFilterMenuItems from './CategoriesFilterMenuItems'
import FollowsFilterMenuItems from './FollowsFilterMenuItems'
export default { export default {
components: { components: {
Dropdown, Dropdown,
FilterPostsMenuItems, CategoriesFilterMenuItems,
FollowsFilterMenuItems,
}, },
props: { props: {
placement: { type: String }, placement: { type: String },

View File

@ -1,7 +1,5 @@
<template> <template>
<ds-container> <ds-space>
<categories-filters :chunk="chunk" />
<ds-space />
<ds-flex id="filter-posts-by-followers-header"> <ds-flex id="filter-posts-by-followers-header">
<ds-heading tag="h4">{{ $t('filter-posts.general.header') }}</ds-heading> <ds-heading tag="h4">{{ $t('filter-posts.general.header') }}</ds-heading>
<ds-space margin-bottom="large" /> <ds-space margin-bottom="large" />
@ -36,19 +34,14 @@
</ds-flex-item> </ds-flex-item>
<ds-space margin-bottom="large" /> <ds-space margin-bottom="large" />
</ds-flex> </ds-flex>
</ds-container> </ds-space>
</template> </template>
<script> <script>
import { mapGetters, mapMutations } from 'vuex' import { mapGetters, mapMutations } from 'vuex'
import CategoriesFilters from './CategoriesFilters'
export default { export default {
components: {
CategoriesFilters,
},
props: { props: {
user: { type: Object, required: true }, user: { type: Object, required: true },
chunk: { type: Array, default: () => [] },
}, },
computed: { computed: {
...mapGetters({ ...mapGetters({