Welcome to mirror list, hosted at ThFree Co, Russian Federation.

project_avatar.stories.js « components « vue_shared « javascripts « assets « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: bfb30c74cb837d81ffb99b04e9962d89c1458461 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import ProjectAvatar from './project_avatar.vue';

export default {
  component: ProjectAvatar,
  title: 'vue_shared/project_avatar',
};

const Template = (args, { argTypes }) => ({
  components: { ProjectAvatar },
  props: Object.keys(argTypes),
  template: '<project-avatar v-bind="$props" />',
});

export const Default = Template.bind({});
Default.args = {
  projectAvatarUrl: 'https://gitlab.com/uploads/-/system/project/avatar/278964/project_avatar.png',
  projectName: 'GitLab',
};

export const FallbackAvatar = Template.bind({});
FallbackAvatar.args = {
  projectName: 'GitLab',
};

export const EmptyAltTag = Template.bind({});
EmptyAltTag.args = {
  ...Default.args,
  alt: '',
};