debian-mirror-gitlab/app/assets/javascripts/ide/components/nav_form.vue

43 lines
935 B
Vue
Raw Normal View History

2018-11-18 11:00:15 +05:30
<script>
import Tabs from '~/vue_shared/components/tabs/tabs';
import Tab from '~/vue_shared/components/tabs/tab.vue';
import BranchesSearchList from './branches/search_list.vue';
import MergeRequestSearchList from './merge_requests/list.vue';
export default {
components: {
Tabs,
Tab,
BranchesSearchList,
MergeRequestSearchList,
},
2020-03-09 13:42:32 +05:30
props: {
showMergeRequests: {
type: Boolean,
required: false,
default: true,
},
},
2018-11-18 11:00:15 +05:30
};
</script>
<template>
2019-02-15 15:39:39 +05:30
<div class="ide-nav-form p-0">
2020-03-09 13:42:32 +05:30
<tabs v-if="showMergeRequests" stop-propagation>
2019-02-15 15:39:39 +05:30
<tab active>
2020-05-24 23:13:21 +05:30
<template #title>
2020-03-09 13:42:32 +05:30
{{ __('Branches') }}
2018-11-18 11:00:15 +05:30
</template>
2020-03-09 13:42:32 +05:30
<branches-search-list />
2018-11-18 11:00:15 +05:30
</tab>
<tab>
2020-05-24 23:13:21 +05:30
<template #title>
2020-03-09 13:42:32 +05:30
{{ __('Merge Requests') }}
2018-11-18 11:00:15 +05:30
</template>
2020-03-09 13:42:32 +05:30
<merge-request-search-list />
2018-11-18 11:00:15 +05:30
</tab>
</tabs>
2020-03-09 13:42:32 +05:30
<branches-search-list v-else />
2018-11-18 11:00:15 +05:30
</div>
</template>