Merge pull request #1689 from Human-Connection/1659-remove-sleep-icon

Remove sleep icon from comments list
This commit is contained in:
mattwr18 2019-09-24 10:59:29 +02:00 committed by GitHub
commit 5e35fd6546
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 10 deletions

View File

@ -1,6 +1,5 @@
import { config, mount, createLocalVue } from '@vue/test-utils'
import CommentList from './CommentList'
import Empty from '~/components/Empty'
import Vuex from 'vuex'
import Styleguide from '@human-connection/styleguide'
import Filters from '~/plugins/vue-filters'
@ -70,11 +69,6 @@ describe('CommentList.vue', () => {
wrapper = Wrapper()
})
it('displays a message icon when there are no comments to display', () => {
propsData.post.comments = []
expect(Wrapper().findAll(Empty)).toHaveLength(1)
})
it('displays a comments counter', () => {
expect(wrapper.find('span.ds-tag').text()).toEqual('1')
})

View File

@ -12,7 +12,7 @@
>
{{ post.comments.length }}
</ds-tag>
&nbsp; Comments
<span class="list-title">{{ $t('common.comment', null, 0) }}</span>
</span>
</h3>
<ds-space margin-bottom="large" />
@ -26,17 +26,14 @@
@updateComment="updateCommentList"
/>
</div>
<hc-empty v-else name="empty" icon="messages" />
</div>
</template>
<script>
import Comment from '~/components/Comment.vue'
import HcEmpty from '~/components/Empty.vue'
export default {
components: {
Comment,
HcEmpty,
},
props: {
post: { type: Object, default: () => {} },
@ -50,3 +47,9 @@ export default {
},
}
</script>
<style lang="scss" scoped>
.list-title {
margin-left: $space-x-small;
}
</style>