Skip to content

Commit

Permalink
fix(files): disable file sidebar routes while loading
Browse files Browse the repository at this point in the history
  • Loading branch information
josephmcg committed May 6, 2022
1 parent 0301660 commit f84d8e2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions components/views/files/aside/List/List.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<ul class="menu-list">
<li
v-for="item in items"
:class="{'is-active' : isActiveRoute(item.route)}"
@click="setActive(item.route)"
:class="[{'is-active' : isActiveRoute(item.route)}, {'disabled' : isFilesIndexLoading}]"
@click="!isFilesIndexLoading && setActive(item.route)"
>
<component v-if="item.icon" :is="icons[item.icon]" size="1x" />
{{item.text}}
Expand Down
2 changes: 2 additions & 0 deletions components/views/files/aside/List/List.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

<script lang="ts">
import Vue, { PropType } from 'vue'
import { mapGetters } from 'vuex'
import {
ClockIcon,
TrashIcon,
Expand All @@ -27,6 +28,7 @@ export default Vue.extend({
},
},
computed: {
...mapGetters('ui', ['isFilesIndexLoading']),
icons() {
return {
[FileIconsEnum.CLOCK]: ClockIcon,
Expand Down

0 comments on commit f84d8e2

Please sign in to comment.