summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/search/sidebar/constants/confidential_filter_data.js
blob: ecb63ed9eea7892fc25f5d4643c0e039282f379f (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
30
31
32
33
34
35
36
import { __ } from '~/locale';

const header = __('Confidentiality');

const filters = {
  ANY: {
    label: __('Any'),
    value: null,
  },
  CONFIDENTIAL: {
    label: __('Confidential'),
    value: 'yes',
  },
  NOT_CONFIDENTIAL: {
    label: __('Not confidential'),
    value: 'no',
  },
};

const scopes = {
  ISSUES: 'issues',
};

const filterByScope = {
  [scopes.ISSUES]: [filters.ANY, filters.CONFIDENTIAL, filters.NOT_CONFIDENTIAL],
};

const filterParam = 'confidential';

export const confidentialFilterData = {
  header,
  filters,
  scopes,
  filterByScope,
  filterParam,
};