diff --git a/webapp/components/PostCard/index.spec.js b/webapp/components/PostCard/PostCard.spec.js similarity index 98% rename from webapp/components/PostCard/index.spec.js rename to webapp/components/PostCard/PostCard.spec.js index 26d0515d6..ab902f05a 100644 --- a/webapp/components/PostCard/index.spec.js +++ b/webapp/components/PostCard/PostCard.spec.js @@ -2,7 +2,7 @@ import { config, shallowMount, mount, createLocalVue, RouterLinkStub } from '@vu import Styleguide from '@human-connection/styleguide' import Vuex from 'vuex' import Filters from '~/plugins/vue-filters' -import PostCard from '.' +import PostCard from './PostCard.vue' const localVue = createLocalVue() diff --git a/webapp/components/PostCard/PostCard.story.js b/webapp/components/PostCard/PostCard.story.js index 1f9f70110..1e470ce11 100644 --- a/webapp/components/PostCard/PostCard.story.js +++ b/webapp/components/PostCard/PostCard.story.js @@ -1,6 +1,6 @@ import { storiesOf } from '@storybook/vue' import { withA11y } from '@storybook/addon-a11y' -import HcPostCard from '~/components/PostCard' +import HcPostCard from './PostCard.vue' import helpers from '~/storybook/helpers' helpers.init() @@ -76,3 +76,23 @@ storiesOf('Post Card', module) /> `, })) + .add('pinned by admin', () => ({ + components: { HcPostCard }, + store: helpers.store, + data: () => ({ + post: { + ...post, + pinnedBy: { + id: '4711', + name: 'Ad Min', + role: 'admin', + }, + }, + }), + template: ` + + `, + })) diff --git a/webapp/components/PostCard/index.vue b/webapp/components/PostCard/PostCard.vue similarity index 94% rename from webapp/components/PostCard/index.vue rename to webapp/components/PostCard/PostCard.vue index 84c5e8073..e1c63c121 100644 --- a/webapp/components/PostCard/index.vue +++ b/webapp/components/PostCard/PostCard.vue @@ -1,7 +1,7 @@