Base.vue 1.04 KB
Newer Older
1
<template>
Eliot Berriot's avatar
Eliot Berriot committed
2
  <div class="main pusher"  v-title="labels.title">
3
4
5
    <div class="ui secondary pointing menu">
      <router-link
        class="ui item"
6
        :to="{name: 'manage.library.files'}"><translate>Files</translate></router-link>
7
8
9
      <router-link
        class="ui item"
        :to="{name: 'manage.library.requests'}">
10
          <translate>Import requests</translate>
11
12
          <div
            :class="['ui', {'teal': $store.state.ui.notifications.importRequests > 0}, 'label']"
Eliot Berriot's avatar
Eliot Berriot committed
13
            :title="labels.pendingRequests">
14
15
            {{ $store.state.ui.notifications.importRequests }}</div>
          </router-link>
16
17
18
19
20
21
    </div>
    <router-view :key="$route.fullPath"></router-view>
  </div>
</template>

<script>
Eliot Berriot's avatar
Eliot Berriot committed
22
23
24
25
26
27
28
29
30
31
32
33
export default {
  computed: {
    labels () {
      let title = this.$gettext('Manage library')
      let pendingRequests = this.$gettext('Pending import requests')
      return {
        title,
        pendingRequests
      }
    }
  }
}
34
</script>
Renon's avatar
Renon committed
35
36
37
38
39
40
41
42
43

<style scoped>

.ui.menu .item > .label {
  position: absolute;
  right: -2em;
}

</style>