summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/ide/components/ide_project_branches_tree.vue
blob: eb2749e6151e0973aad605726c51f1c998065a76 (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
37
38
39
40
41
42
43
44
45
46
47
<script>
  import icon from '~/vue_shared/components/icon.vue';
  import repoTree from './ide_repo_tree.vue';
  import newDropdown from './new_dropdown/index.vue';

  export default {
    components: {
      repoTree,
      icon,
      newDropdown,
    },
    props: {
      projectId: {
        type: String,
        required: true,
      },
      branch: {
        type: Object,
        required: true,
      },
    },
  };
</script>

<template>
  <div class="branch-container">
    <div class="branch-header">
      <div class="branch-header-title str-truncated ref-name">
        <icon
          name="branch"
          :size="12"
        />
        {{ branch.name }}
      </div>
      <div class="branch-header-btns">
        <new-dropdown
          :project-id="projectId"
          :branch="branch.name"
          path=""
        />
      </div>
    </div>
    <repo-tree
      :tree="branch.tree"
    />
  </div>
</template>