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

noteable.js « mixins « notes « javascripts « assets « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 0da4ff49f0862136687a9209957d45c7f01e64ad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import * as constants from '../constants';

export default {
  props: {
    note: {
      type: Object,
      required: true,
    },
  },
  computed: {
    noteableType() {
      switch (this.note.noteable_type) {
        case 'MergeRequest':
          return constants.MERGE_REQUEST_NOTEABLE_TYPE;
        case 'Issue':
          return constants.ISSUE_NOTEABLE_TYPE;
        default:
          return '';
      }
    },
  },
};