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

errors_alert.stories.js « form « 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: 7c32e38a299337d9d0400b66084f825912857081 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
import ErrorsAlert from './errors_alert.vue';

export default {
  component: ErrorsAlert,
  title: 'vue_shared/form/errors_alert',
};

const defaultProps = {
  errors: ['Name must be at least 5 characters.', 'Name cannot contain special characters.'],
};

const Template = (args) => ({
  components: { ErrorsAlert },
  data() {
    return { errors: args.errors };
  },
  template: `<errors-alert v-model="errors" />`,
});

export const Default = Template.bind({});
Default.args = defaultProps;